pl/sql code hanging
Hi,
Not sure if I wrote something wrong in this code - this is hanging
1 declare
2 id1 t4.id%TYPE;
3 name1 t4.name%TYPE;
4 c1 sys_refcursor;
5 begin
6 open c1 for select t4.id,name from t4,t where t4.id=t.id;
7 loop
8 fetch c1 into id1,name1;
9 dbms_output.put_line(name1||'and'||id1);
10 end loop;
11* end;
SQL> /
SQL> select count(*) from t4,t where t4.id=t.id;
COUNT(*)
----------
260
Best regards,
Vishal