Trigger updating same table

Triggers can be: Trigger names must be unique with respect to other triggers in the same schema.

A trigger is fired based on a triggering statement, which specifies: statement might include a list of columns. Deptno) AS Amp_list_ Emplist FROM Dept_tab d; The statement level triggers are useful for performing validation checks for the entire statement.TR_TB_TR_TEST", line 2 ORA-04088: error during execution of trigger 'HR.Here is what I came up with: I had set a constraint on the Answer Modified with a default value = 0, so I amm thinking that would suffice for an update of the Modified Answer.create or replace trigger TR_TB_TR_TEST 2 before insert on TB_TR_TEST 3 for each row 4 begin 5 SELECT max(col1) 1 INTO : NEW.col1 6 FROM TB_TR_TEST; 7 UPDATE TB_TR_TEST SET col2 = 5000; 8 end; 9 / Trigger created insert into TB_TR_TEST(col1, col2) 2 select 1, 2 3 from dual; insert into TB_TR_TEST(col1, col2) select 1, 2 from dual ORA-04091: table HR.TB_TR_TEST is mutating, trigger/function may not see it ORA-06512: at "HR.

Leave a Reply