Subject Re: [ib-support] Trigger question
Author Ivan Prenosil
> I'm wondering if a trigger can cause a deadlock ?

There is nothing special about triggers - if the statment can cause deadlock,
than the same statement in trigger will cause deadlock too.


> I guess triggers are
> out of transaction control ?

No, triggers run in the context of the same transaction
as the statment that caused trigger to fire.

> Example : User X is inserting a record in
> table A, a after insert trigger is updating a record in table B, and user Y
> is busy changing that same record from table B --> could that situation
> cause a deadlock ?

It will not cause deadlock but rather update conflict.
(that is however sometimes reported as deadlock).

Ivan
prenosil@...
http://www.volny.cz/iprenosil/interbase