My bad ... I was testing it with ...
... instead of ...Code:SQL> create table my_tab2 (my_date references my_table(my_date)); create table my_tab2 (my_date references my_table) * ERROR at line 1: ORA-02268: referenced table does not have a primary key
Code:SQL> create table my_tab2 (my_date references my_table(my_date)); Table created.
Anyhoo, I don't see an advantage in this case in defining an AK instead of a PK -- it sounds like a disadvantage as far as maintainability goes.
the real problem is that column being the key on table 1, i think, but i guess you can't do much about that.




Reply With Quote