sub line {
my($self,$datasrc)=@_;
my($null)=$self->null;
- $null ||= "NOT NULL" if $datasrc =~ /mysql/; #yucky mysql hack
+ if ( $datasrc =~ /mysql/ ) { #yucky mysql hack
+ $null ||= "NOT NULL"
+ }
+ if ( $datasrc =~ /Pg/ ) { #yucky Pg hack
+ $null ||= "NOT NULL";
+ $null =~ s/^NULL$//;
+ }
join(' ',
$self->name,
$self->type. ( $self->length ? '('.$self->length.')' : '' ),
L<FS::dbdef_table>, L<FS::dbdef>, L<DBI>
+=head1 VERSION
+
+$Id: dbdef_column.pm,v 1.2 1998-10-12 23:40:28 ivan Exp $
+
=head1 HISTORY
class for dealing with column definitions
mySQL-specific hack for null (what should be default?) ivan@sisd.com 98-jun-2
+$Log: dbdef_column.pm,v $
+Revision 1.2 1998-10-12 23:40:28 ivan
+added Pg-specific behaviour in sub line
+
+
=cut
1;