Home » RDBMS Server » Server Administration » Calling Procedure/Functions dynamically......Urgent !!!!!!!!!!
Calling Procedure/Functions dynamically......Urgent !!!!!!!!!! [message #370770] Thu, 03 February 2000 09:38 Go to next message
Ajay Madan
Messages: 8
Registered: January 2000
Junior Member
My application is in Oracle8i(server) with Developer6 as Front End. The application requires that PL/SQL procedures and Functions be called dynamically. The procedure names are stored in a table which will be queried and executed.

The problem is that although there are built-ins which return the value stored in a variable, we do not know how to execute the Procedure name returned by the variable without hardcoding the value.

return_value := (name_in('Parameter.procname'))

A statement like the one above only returns the proc/function name but does not execute it.

How can we execute the 'Proc/Function name' returned?
Re: Calling Procedure/Functions dynamically......Urgent !!!!!!!!!! [message #370777 is a reply to message #370770] Sat, 05 February 2000 07:25 Go to previous message
Padmavathy
Messages: 1
Registered: February 2000
Junior Member
8i Release 2 Version Solves this Problem.
With RETURNING Clause.
Goto REVEALNET Site on 8i for further info.

Here is an Example :

DECLARE
lbalance accounts.balance%TYPE;
lopen_date accounts.open_date%TYPE;
BEGIN
EXECUTE IMMEDIATE
'SELECT balance, open_date
FROM accounts
WHERE account_id = 104736'
INTO lbalance, lopen_date;
END;
Previous Topic: URGENT Syntax question Dynamic SQL.
Next Topic: Re: Interview
Goto Forum:
  


Current Time: Tue Oct 20 10:18:28 CDT 2020