Discussion
Which of the following is TRUE about mutating tables in PL/SQL triggers ?
Answer: A
Mutating tables cannot be queried or modified during trigger execution.
A table is 'mutating' while a DML statement is changing it. Oracle does not allow a row-level trigger on that table to read or change it, because the result would depend on the order in which rows happen to be processed. A trigger that tries raises the run-time error ORA-04091 (table is mutating, trigger/function may not see it).
So the table cannot be modified freely inside a row-level trigger. The problem shows at run time, not as a compilation error, and the restriction lasts only while the statement executes; nothing is locked permanently.
Post your comment
Please log in or register to post a comment.
Examination Categories
- SSC Exams
- Banking Exams
- Teaching Exams
- Civil Services Exams
- Railways Exams
- Engineering Recruitment Exams
- Defence Exams
- State Government Exams
- Police Exams
- Insurance Exams
- Nursing Exams
- Other Government Exams
- NRA CET
- PG Entrance Exams
- Campus Placement
- MBA Entrance Exams
- CUET and UG Entrance
- Judiciary Exams
- Regulatory Body Exams
- Software Development