Subject Re: [firebird-support] Debugging cascaded updates
Author Helen Borrie
At 03:12 AM 5/11/2004 +0000, you wrote:

>I need some suggestions here. I have a table whose primary key is the
>foreign key in a number of other tables (about 30 or so). When I try
>to delete a record from this table, I get a funny error message,
>because one of the tables that relies on it has a bug in a before or
>after delete trigger.

"Funny error message" is not very scientific. Debugging, on the other
hand, needs to be quite scientific.


>The other tables are all defined as "on delete cascade".
>
>Is there any quick and easy way of finding which trigger is throwing
>the error message, or is process of elimination the only way?

Knowledge of your metadata would be rather helpful here. I suggest trying
to make sense of your "funny error message" and to look first at the tables
having the most interesting things going on at trigger time. As a pointer
to what you might be looking for, one or more or these dependent tables
might have other tables dependent on them that do not have cascades defined.

./hb