July 15, 2003 at 2:27 pm
I have a main table that has a composite primary key. Made up of:
ID1
ID2
I want to have a foreign key to the ID2 in another table?
Is this allowed? (foreign key to part of a composite primary key)
July 15, 2003 at 2:38 pm
NOPE
Shas3
July 15, 2003 at 2:40 pm
so what can I do?
i need the composite key and I need a FK to it?
July 15, 2003 at 3:33 pm
what are the rules here?
work arounds?
July 15, 2003 at 8:36 pm
these tables with the composite PK are lookup tables. I was thinking about just leaving them as standalone tables(no FK relationship to data tables).
suggestions?
July 17, 2003 at 2:24 am
Why not create a surrogate single column PK in your table, and then that can be referenced by foreign keys in other tables. This way you will maintain integrity.
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply