Reputation:
There are two triggers referencing a table. Both are being triggered after delete or insert or delete on the table.
Which one will run first?
Upvotes: 0
Views: 41
Reputation: 4818
If one is before
and second is after
order is obvious. Also before statement
goes earlier than before each row
. If you have two after insert
documentation says:
Although triggers of different types are fired in a specific order, triggers of the same type for the same statement are not guaranteed to fire in any specific order.
Please also see comment bellow that post by @a_horse_with_no_name Since Oracle 11g you can use follows
and precedes
to control it.
Upvotes: 2