$self->preserve_case(0);
}
elsif ($self->preserve_case) {
- $self->schema->storage->quote_char('"');
- $self->schema->storage->name_sep('.');
+ $self->schema->storage->sql_maker->quote_char('"');
+ $self->schema->storage->sql_maker->name_sep('.');
}
}
$sth->execute($self->_uc($table),$self->{db_schema} );
my %constr_names;
while(my $constr = $sth->fetchrow_arrayref) {
- my $constr_name = $constr->[0];
+ my $constr_name = $self->_lc($constr->[0]);
my $constr_col = $self->_lc($constr->[1]);
$constr_name =~ s/\Q$self->{_quoter}\E//;
$constr_col =~ s/\Q$self->{_quoter}\E//;
$info->{size} = $info->{size} / 2;
}
elsif (lc($info->{data_type}) eq 'number') {
- $info->{data_type} = 'numeric';
+ $info->{original}{data_type} = 'number';
+ $info->{data_type} = 'numeric';
if (eval { $info->{size}[0] == 38 && $info->{size}[1] == 0 }) {
+ $info->{original}{size} = $info->{size};
+
$info->{data_type} = 'integer';
delete $info->{size};
}
$info->{original}{data_type} = 'binary_double';
}
- if (eval { lc(${ $info->{default_value} }) eq 'sysdate' }) {
- $info->{original}{default_value} = $info->{default_value};
-
+ if ((eval { lc(${ $info->{default_value} }) }||'') eq 'sysdate') {
my $current_timestamp = 'current_timestamp';
$info->{default_value} = \$current_timestamp;
+
+ my $sysdate = 'sysdate';
+ $info->{original}{default_value} = \$sysdate;
}
}