Posts

Showing posts from April, 2021

How to Solve Mutating Trigger Using Compound trigger

  How to Solve Mutating Trigger Using Compound trigger Mutating ERROR CODE:- CREATE OR REPLACE TRIGGER APPS . XX_EMP_B_U_TRIG   BEFORE   UPDATE   --OF SAL   ON APPS . XX_EMP --REFERENCING OLD AS OLD NEW AS NEW FOR EACH ROW DECLARE V_PRESIDENT_SAL NUMBER ;   BEGIN      dbms_output.put_line ( '============ Row Level   - Before Update Trigger Fired ============' );   select SAL INTO V_PRESIDENT_SAL   from xx_emp where JOB= 'PRESIDENT' ;         IF :NEW. SAL >= V_PRESIDENT_SAL   THEN       dbms_output.put_line ( '*****   You can not assign this salary to anyone   *****' );     RAISE_APPLICATION_ERROR (- 20100 , 'You can not assign this salary to anyone' );       ELSE     dbms_output.put_line ( '***** You Can assign this Salary   *****' ); ...