Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> dynamic procedure calls in PL/SQL
Hi:
I have a pl/sql procedure that needs to be able to call any one of many other procedures. The names of these procedures are carried in a table, and depending on the current circumstance, the appropriate procedure name is selected and then executed. Is there a way to dynamically execute these procedures?
The psuedo looks like this:
CREATE OR REPLACE PROCEDURE pr_tom(an_circumstance number,
otherarguements)
AS
BEGIN
select procedure_name
into variable
from table
where circumstance := an_circumstance;
/* Logically, this is what I want to do
execute variable(otherarguements) /* the arguement list is always the same */
END pr_tom;
Thanks in advance Received on Fri Aug 31 2001 - 12:53:34 CDT