Are there any values in the class column in parts that don't have corresponding values in the PK of the class table?
>>>Bill,
>>>
>>>Must be misunderstanding. I didn't say that CLASS_PK is the primary key in the PARTS table. It is the primary key in the PART_CLASS table (new table). (the PARTS table does have the primary key which is not relevant to this).
>>>
>>
>>OK.
>>
>>How did you go about setting the foreign key restraint?
>>
>>
>
>In SSMS I go to PARTS table, right mouse click on Keys and click on New Foreign Key. Then specify that Primary table is PART_CLASS with column CLASS_PK and Foreign table is PARTS with column CLASS_PK. In the UPDATE specification I set to Default on Delete.
>And then it fails on saving the table.
Anyone who does not go overboard- deserves to.
Malcolm Forbes, Sr.