What are the components of a DML trigger?

Are you preparing for IT certification? With practice questions, study notes, interactive quizzes, tips and technical articles, uCertify PrepKits ensure that you get a solid grasp of core technical concepts to ace your certification exam in first attempt.

What are the components of a DML trigger?

Rating:

A DML trigger is a database trigger whose triggering event is a Data Manipulation Language (DML) statement. A DML trigger has the following components:

  • Trigger timing: It decides the time of the trigger's execution in relation to the triggering event. Possible values are BEFORE, AFTER, and INSTEAD OF. BEFORE specifies that the trigger body will be executed before the triggering event is executed on the associated table. AFTER specifies that the trigger body will be executed after the triggering event is executed on the associated table. INSTEAD OF specifies that the trigger body will be executed instead of the triggering event. INSTEAD OF can be specified only for views and not for tables.


  • Triggering event: It specifies the Data Manipulation Language (DML) statement that causes the trigger to fire. Possible values are INSERT, UPDATE, and DELETE.


  • Trigger type: It determines how many times the trigger body executes. Possible values are statement (default) and row (FOR EACH ROW). Statement specifies that the trigger body will be executed only once for the triggering event, regardless of the number of rows affected by the triggering event. Row specifies that the trigger body will be executed once for each row affected by the triggering event.


  • Trigger body: It determines the action that the trigger will perform when it is fired. The trigger body is a complete PL/SQL block or a CALL statement that calls a stored procedure.

  • Rating:



    Other articles

    Click here to Article home

     
    uCertify.com | Our Company | Articles | Privacy | Security | Contact Us | News and Press Release | uCertify India
    MCSE: MCSA, MCTS, MCITP    JAVA Certification: SCJP, SCWCD Cisco Certification: CCNA, CCENT, A+, Network+, Security+
    Oracle Certification: OCP 9i, OCP 10g, OCA 9i, OCA 10g CIW foundation    EC-212-32    CISSP    Photoshop ACE    Adobe Flash ACE
    © 2008 uCertify.com. All rights reserved. All trademarks are the property of their respective owners.