Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: how would you do it?
> However, I need to be able to run a procedure which name is a part of
> the cursor-for-loop.
so ? concatenate....
something like this ?
DECLARE
l_proc VARCHAR2(2000) ;
BEGIN
for x in (select seq, proc from table t order by seq)
loop
l_proc := l_proc || i.proc || ';' || chr(10) ;
end LOOP ;
l_proc := 'begin' || chr(10) || l_proc || chr(10) || 'end;' ;
execute immediate l_proc ;
END;
Received on Fri Dec 15 2006 - 17:44:14 CST