How to call the function and Procedure in trigger?
Answer Posted / pranabesh
Procedures can be called directly by name with parameters
[if any] in the trigger
ex:
suppose i have a procedure pro1(var1 in number, var2 in
number) which i want to call from trigger trig1
CREATE OR REPLACE TRIGGER TRIG1
AFTER UPDATE OF SAL ON EMP
REFERENCING NEW AS NEW OLD AS OLD
FOR EACH ROW
DECLARE
L_VAR1 NUMBER;
...
...
BEGIN
...
...
-- CALLING THE PROCEDURE
pro1(10,20);
END
Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
What is trigger types of trigger?
How do I make my sql query run faster?
How to use sql*plus built-in timers?
How to run sql*plus commands in sql developer?
Which join condition can be specified using on clause?
How do you break a loop in pl sql?
What are the two types of exceptions in pl/sql?
Does a join table need a primary key?
What is the command used to fetch first 5 characters of the string?
Which kind of parameters cannot have a default value in pl sql?
Explain what is a subquery ?
is mysql query is case sensitive? : Sql dba
What information is needed to connect sql*plus an oracle server?
how can we destroy the session, how can we unset the variable of a session? : Sql dba
How to write a single statement that concatenates the words ?hello? And ?world? And assign it in a variable named greeting?