Subject | primary key not null? |
---|---|
Author | Sergio H. Gonzalez |
Post date | 2009-05-07T20:35:19Z |
[FB 2.1.2.18118]
Hello, I have a little doubt... I thought that a column should be NOT NULL if
you want to use it as a PK, but I have this domain:
CREATE DOMAIN ID AS
NUMERIC(9,0)
and all the tables in my database has a column called "ID" wich is the PK. As a
matter of fact I didn't mean to have that domain as nullable. It was my mistake
I think... But my question is: It's normal that FB didn't complain about having
a PK on a nullable column?
I just realize that I can't edit the "NOT NULL" property of a domain (I use
IBExpert Personal), so I fixed my mistake, extracting all the metadata and data
of my db, altering the script and recreating it...
So, I have no problem, but I'm a bit confused!
Thanks!!
-s
Hello, I have a little doubt... I thought that a column should be NOT NULL if
you want to use it as a PK, but I have this domain:
CREATE DOMAIN ID AS
NUMERIC(9,0)
and all the tables in my database has a column called "ID" wich is the PK. As a
matter of fact I didn't mean to have that domain as nullable. It was my mistake
I think... But my question is: It's normal that FB didn't complain about having
a PK on a nullable column?
I just realize that I can't edit the "NOT NULL" property of a domain (I use
IBExpert Personal), so I fixed my mistake, extracting all the metadata and data
of my db, altering the script and recreating it...
So, I have no problem, but I'm a bit confused!
Thanks!!
-s