Saturday 26 May 2012

What is a CALL statement? Explain with an example. | PL SQL

 A CALL statement within a trigger enables you to call a stored procedure within the trigger rather than writing the Procedural Language/Structured Query Language (PL/SQL) code in it, The procedure may be in PL/SQL, C, or Java language. Following is an example of the CALL statement:
CREAT OR REPLASE TRIGGER<trigger_name>
BEFORE UPDATE OF <column_name> ON <table_name>
FOR EACH ROW
WHEN <condition_clause>
CALL <procedure_name>