Tell Me
 

DML Triggers

Previous previous|next Next Page


Syntax for creating a DML trigger

CREATE [OR REPLACE] TRIGGER trigger_name
timing
event1 [OR event2 OR event3]
ON object_name
[ [REFERENCING OLD AS old/NEW AS new]
FOR EACH ROW
[WHEN (condition)] ]
trigger_body

 

The components of the syntax are:

  • trigger_name
  • timing
  • event
  • object_name
  • REFERENCING
  • WHEN
  • trigger_body

Types of DML Triggers:

  • Statement trigger
  • Row trigger.