|Subject||Re: [firebird-support] Foreign key reference target does not exist. [FB 2.5 beta 2]|
>> I tried to create a foreign key but I always get this error:Sorry, but this is wrong.
>> violation of FOREIGN KEY constraint "".
>> violation of FOREIGN KEY constraint "FK_RES_TREEVIEW_1" on table
>> Foreign key reference target does not exist.
> this usually means you have not committed the table creation BEFORE you
> attempt to craete the foreign key. i.e. "Foreign key reference target does
> not exist."
a) you can issue as many DDL statements in the same transaction as you need
b) what you should not do - is to issue DML after DDL in the same transaction
(not this case)
c) error means exactly what message said - no master record with key value
corresponding to the some child record(s)