If trigger exists, drop trigger : Drop Trigger « Trigger « Oracle PL/SQL Tutorial






SQL>
SQL> BEGIN
  2    FOR i IN (SELECT null FROM user_triggers WHERE trigger_name = 'INSERTemp') LOOP
  3      EXECUTE IMMEDIATE 'DROP TRIGGER InsertBooksemp';
  4    END LOOP;
  5  END;
  6  /

PL/SQL procedure successfully completed.

SQL>








28.9.Drop Trigger
28.9.1.Dropping a Trigger
28.9.2.If trigger exists, drop trigger