create or replace procedure show_tab_rec ( P_tab VARCHAR2 )
IS
cmd varchar2(50);
begin
cmd := 'select *
from '|| P_tab;
for int in ( execute immediate cmd )
loop
dbms_output.put_line ( int.ename||' '||int.deptno);
end loop;
end;
when i m compling this procedure i m getting this error
PLS-00103: Encountered the symbol "IMMEDIATE" when expecting
one
of the following:
. ( ) , * @ % & | = - + < / > at in is mod remainder not
range rem => .. <an exponent (**)> <> or != or ~= >= <= <>
and or like LIKE2_ LIKE4_ LIKEC_ between || multiset member
SUBMULTISET_
PLZ solve this error
give this question answer asap
Thanks advance.......
Answer / satish
we can't use execute immediate in for loop cursor.So,we can
use ref cursor instead of this to achieve this solution
| Is This Answer Correct ? | 2 Yes | 0 No |
What privilege is needed for a user to create indexes in oracle?
What is program global area (pga) in oracle?
What are the general rules on data consistency?
Give the constructs of a package, function or a procedure.
How would you edit your CRONTAB to schedule the running of /test/test.sh to run every other day at 2PM?
Explain overloading. Can functions be overloaded?
what is the syntax of ALTER command?
What are the numeric comparison operations?
There are three tables : E : EID,ENAME D : DID,DNAME empdept : eid, did select the employees who doesn't belong to any dep
What is oracle analytical function?
How do I limit the number of oracle database connections generated by weblogic server?
what is reindexing?