Subject | Re: [firebird-support] Question on Ref Integrity during Trigger |
---|---|
Author | Helen Borrie |
Post date | 2005-10-09T00:59:13Z |
At 12:32 PM 8/10/2005 -0700, Myles Wakeham wrote:
structures of the two tables, together with the definitions of the keys.
./heLen
>I am attempting to update a separate table with data in the AFTER INSERTMyles, this description is too vague and ambiguous. Provide the key
>phase of a trigger. But there is a foreign key constraint on the table I
>wish to create new records in, as a result of the insert into the table with
>the trigger. This constraint requires that the data in the table I'm
>updating already be in existence.
>
>Hence when I go to create the additional records in the related table, I get
>a 'Violation of foreign key constraint' as I can't insert new records in
>this table that reference the record I'm creating. I guess its because that
>record hasn't actually been saved when the trigger is firing?
structures of the two tables, together with the definitions of the keys.
>Anyway what is the trick here? Do I have to manually drop the foreign keyNo. Let's get a clear picture of the situation here.
>constraint
./heLen