What is mutating trigger? How do you resolve it?If a trigger body is trying to update dependent tables, will it get a mutating error?

Showing Answers 1 - 13 of 13 Answers


  • Dec 3rd, 2006

Mutating trigger is trigger that is currently being modified by DML opertion.

we can resolve it by applying statement lelel trigger.


Pawan Ahuja


  • Dec 8th, 2006

if the trigger attempts to select or modify the table while the trigger has not completed (ie. table is in transition). then mutating trigger error occurs.

 because the table is in middle of a transaction so it causes the trigger to mutate.

you can change the trigger to statement level and apply the logic there.

  Was this answer useful?  Yes

Mutating trigger has similar concept to that of deadlock. When a table is in the half way of executing a transaction and is the owner of a trigger and if the same table is accessed by the trigger somewhere else in the same time then at that instance mutating trigger occurs.

  Was this answer useful?  Yes

To avoid Mutating trigger there are many ways. One of the best approach is to make use of the after trigger which clearly takes care of concurrency problems associated with mutating triggers .When after trigger is used only after the process of current updating is finished the next process gets processed.


  • Dec 11th, 2008

Mutating trigger is trigger that is currently being modified by DML opertion. For eg.,
You created a trigger trigger1 on table1, it should fire after update for each row. And you wrote some update statement on the same table (table1) inside the trigger . When you execute the individual update stmt on table1, the trigger get fires and the trigger also is currently being updated the same rows in table1, which is called mutating error and mutating trigger.


  • Dec 23rd, 2008

Mutating table is table which is modified by any DML statement.
It is inconsistent mode and we write row level trigger to solve it.

  Was this answer useful?  Yes

There are cases when we have mutating table error inspite of using an "AFTER TRIGGER at ROW LEVEL".  This happens when you are using an after delete trigger.  For instance a delete was issued and the trigger gets fired.at the same time it also needs the count of the records in the table.  In such a case,it gives a mutation error.  This can be solved by make it a statement level trigger.  Because in such a case, the table count is queried after the delete is fully executed.

  Was this answer useful?  Yes

maxin john

  • Jun 8th, 2015

soo...... how you are going to use that lelel trigger :O

  Was this answer useful?  Yes


  • Nov 18th, 2015

A mutating table is a table that is being modified by an UPDATE, DELETE, or INSERT statement. The session that issued the triggering statement cannot query or modify a mutating table. If you must update a mutating table, you can bypass these restrictions by using a temporary table, a PL/SQL table, or a package variable. For example, in place of a single AFTER row trigger that updates the original table, resulting in a mutating table error, you might use two triggers—an AFTER row trigger that updates a temporary table, and an AFTER statement trigger that updates the original table with the values from the temporary table.

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

Answer Question

Click here to Login / Register your free account

Send   Reset


Related Answered Questions


Related Open Questions