Re: Disabling Fkey Constraint & there of ..

From: <U19822_at_uicvm.uic.edu>
Date: 1996/04/25
Message-ID: <96116.234818U19822_at_uicvm.uic.edu>#1/1


> jp_at_queen.plaza.nt.com (JP Srinath) wrote:
>
>>I think you are missing the point here. Let me try to explain what I am
>> trying to do.
 

>> I want to make some some structural changes to the parent table - So I
>> intend to export the data, disable Fkey of the children, drop the parent
>> , recreate the parent, import data & enable the Fkey of the children.
 

>> Why should the DBMS stop me from dropping the parent ? I know very well
>> that the children are hanging in the air - but at the same time I can
>> make sure that all the Fkey's are present in the parent before I enable
>> the Fkey constraint !
 

>> The point here is, I need to do more typing in order to do this
>> because, it seems that the only way I can do it is by 'droping the table
>>with cascade constraints' (as you suggested) - and recreating the constraints
 

>> Is this the only way to accomplish the task in other environments like db2
>> etc., ?
 

>> I can understand the reasons behind this, but at the same time I need
>> to type more u know ????
>
>
>> Thanks ,
 

>> JP

   You need to drop the foreign key constraint before dropping the parent table. Otherwise the fk constraint would be invalid due to the fact that the table it reference to does not exist. Received on Thu Apr 25 1996 - 00:00:00 CEST

Original text of this message