Best Hacks

Saturday 11 August 2012

What are PL/SQL Triggers





PL/SQL Triggers

A trigger is a PL/SQL block which will run automatically whenever an event occurs. PL/SQL block may be associated with a table, a view or to a database. OR simply, A trigger is a procedure to be run automatically when it is launched on the table associated with a command to the insert, update, or delete.

The general syntax is :


CREATE OR REPLACE TRIGGER trigger_name
{BEFORE | AFTER | INSTEAD OF}
{INSERT | UPDATE | DELETE}
[OF column_name]
ON table_name
[REFERENCING OLD AS old NEW AS new]
[FOR EACH ROW]
WHEN (condition)
BEGIN
--- pl/sql statements
END;
Like Us.... Receive updates on your Facebook wall!!!!
 

Something About Author:

Page Views

Visitors

free counters
Follow Me on Pinterest

Follow Us:

Do Not Copy

Google PageRank Checker Powered by  MyPagerank.Net