Subject | Re: [firebird-support] Problem with AUTONOMOUS TRANSACTION |
---|---|
Author | Helen Borrie |
Post date | 2015-08-08T03:20:38Z |
At 02:51 p.m. 8/08/2015, 'Walter R. Ojeda Valiente' sistemas2000profesional@... [f wrote:
Some Caveats
1. The use of the IN AUTONOMOUS TRANSACTION DO statement in the database event triggers related to transactions (TRANSACTION START, TRANSACTION ROLLBACK, TRANSACTION COMMIT) may cause the autonomous transaction to enter an infinite loop
Helen
>Hello everybodyFrom the forthcoming Firebird 2.5 Language Reference manual (yes, people, it is coming!)
>
>Do you know why this simple trigger "hang-up" the database?
>
>CREATE TRIGGER TRANSACCION_INICIA
>ACTIVE ON TRANSACTION START
>POSITION 0
>AS
>BEGIN
>Â Â
>Â Â IN AUTONOMOUS TRANSACTION DO BEGIN
>Â Â
>Â Â END
>Â Â
>END;
>
>
>Always when I put "IN AUTONOMOUS TRANSACTION" the database crash. Without those words everything works fine.
>
>It is not possible to use autonomous transactions inside a database trigger?
Some Caveats
1. The use of the IN AUTONOMOUS TRANSACTION DO statement in the database event triggers related to transactions (TRANSACTION START, TRANSACTION ROLLBACK, TRANSACTION COMMIT) may cause the autonomous transaction to enter an infinite loop
Helen