Subject | Re: [firebird-support] Null Foreign Keys |
---|---|
Author | Milan Babuskov |
Post date | 2003-09-11T15:51:11Z |
Ed Dressel wrote:
Here:
SQL> create table a ( x int not null, primary key (x));
SQL> create table b ( y int);
SQL> commit;
SQL> alter table b add constraint c foreign key (y) references a(x);
SQL> commit;
SQL> insert into b values (null);
SQL> commit;
As you can see, I have inserted NULL in FK column. Does that answer the
question?
--
Milan Babuskov
http://fbexport.sourceforge.net
> Does FB support null foreign keys? I though I saw mention of this butWhy can't you just test?
> can not find anything on it.
Here:
SQL> create table a ( x int not null, primary key (x));
SQL> create table b ( y int);
SQL> commit;
SQL> alter table b add constraint c foreign key (y) references a(x);
SQL> commit;
SQL> insert into b values (null);
SQL> commit;
As you can see, I have inserted NULL in FK column. Does that answer the
question?
--
Milan Babuskov
http://fbexport.sourceforge.net