Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: PL/SQL Function Calls
Bullseye wrote:
> HI
>
> from within a PL/SQL procedure, is it possible to call another
> procedure whose name is passed in as an argument (IE not known until
> run time).
>
> For example:-
>
>
> PROCEDURE test (ProcName) IS
> BEGIN
> DECLARE
>
> BEGIN
> << do something>>
>
> < Execute Procedure 'ProcName' as passed in Arguments >>;
>
> << do something else
> END;
> END;
>
> Example of Calling Procedure:-
>
> BEGIN
> test( 'UserProc1(Param)' );
> test( 'UserProc2(Param)' );
> test( 'UserProc3(Param)' );
> END;
>
> TIA
Yes... by using dynamic sql. Goto http://tahiti.oracle.com and lookup
usage for DBMS_SQL package.
Regards
/Rauf
Received on Mon Jun 06 2005 - 06:33:16 CDT