Foreign Keys to Non-primary keys?
Foreign Keys to Non-primary keys?
От:
zilch@home.se
Дата:
Is it possible to have a foreign key to a non-primary key (also meaning non-unique and therefore non-indexed) column i a table? I can only imagine the performance loss... --- Daniel Åkerud, zilch@home.se
Re: Foreign Keys to Non-primary keys?
От:
Stephan Szabo <sszabo@megazone23.bigpanda.com>
Дата:
On Thu, 21 Jun 2001 zilch@home.se wrote: > > Is it possible to have a foreign key to a non-primary key (also > meaning non-unique and therefore non-indexed) column i a table? Generally no. It's not allowed by the spec, so as of 7.1, we prevent it. Admittedly, you could pull the rug out from underneath it by dropping the index, though.