Subject Re: [firebird-support] Primary key Not Null?
Author Martijn Tonies
Hello Kevin,

> I'm using FB 1.5. (1.5.2 I believe).
> I just discovered today that if I declare a field as a primary key, I
> still need to declare this field as not null. I believe that by
> definition a primary key is unique and not null. So by me declaring a
> field as a primary key should automatically mean that the field had to
> be unique and not null?
> Why was it was implemented that way? Very curious. I believe that it's
> an either or in the database world (i.e. some do it like FB and others
> do it automatically).

Right, some GUI tools do this automatically as well ;-)

Anyway, I bet it's just an oversight...

With regards,

Martijn Tonies
Database Workbench - tool for InterBase, Firebird, MySQL, Oracle & MS SQL
Upscene Productions
Database development questions? Check the forum!