Re: After statement level trigger iring before after row level trigger

From: sybrandb <sybrandb_at_gmail.com>
Date: Thu, 19 Mar 2009 06:12:37 -0700 (PDT)
Message-ID: <2a52de18-7cc4-416f-b99a-0f14754b3c34_at_q9g2000yqc.googlegroups.com>



On 19 mrt, 11:18, PeteDaMeat <peterlaz..._at_gmail.com> wrote:
> On Mar 19, 9:47 am, "Laurenz Albe" <inv..._at_spam.to.invalid> wrote:
>
>
>
>
>
> > PeteDaMeat wrote:
> > > I have a database table which has anafterstatementleveltrigger
> > >firingbefore theafterrow leveltrigger, does anyone have any
> > > suggestions as to what could be causing this?
>
> > This is caused by the Oracle database engine.
> > The behaviour is documented inhttp://download-uk.oracle.com/docs/cd/B19306_01/server.102/b14220/tri...
>
> > For enabled triggers, Oracle automatically performs the following actions:
>
> >  * Oracle runs triggers of each type in a plannedfiringsequence when
> >    more than onetriggeris fired by a single SQLstatement.
> >    First,statementlevel triggers are fired, and then row level triggers are fired.
> > [...]
> >  * Oracle fires multiple triggers in an unspecified, random order, if more
> >    than onetriggerof the same type exists for a givenstatement;
> >    that is, triggers of the same type for the samestatementare
> >    not guaranteed to fire in any specific order.
>
> > Yours,
> > Laurenz Albe
>
> That is different to the documentation I have:
>
> Oracle uses the following execution model to maintain the proper
> firing sequence of multiple triggers and constraint checking:
>
> Run all BEFORE statement triggers that apply to the statement.
> Loop for each row affected by the SQL statement.
> Run all BEFORE row triggers that apply to the statement.
> Lock and change row, and perform integrity constraint checking. (The
> lock is not released until the transaction is committed.)
> Run all AFTER row triggers that apply to the statement.
> Complete deferred integrity constraint checking.
> Run all AFTER statement triggers that apply to the statement.
>
> Pete- Tekst uit oorspronkelijk bericht niet weergeven -
>
> - Tekst uit oorspronkelijk bericht weergeven -

As you never provided version info, deeming that unimportant, as Oracle never changes, no further assistance is possible.

--
Sybrand Bakker
Senior Oracle DBA
Received on Thu Mar 19 2009 - 08:12:37 CDT

Original text of this message