This content has been marked as final. Show 2 replies
Did you set the parameter:
set serveroutput on
? When set to off it doesn't prevent select statements from showing data, but dbms_output calls output isn't shown.
Edited by: apiminov on 14.11.2012 1:07
Try like ......
TYPE list_of_names_t IS TABLE OF VARCHAR2(100);
happyfamily list_of_names_t ;
CURSOR names_cur IS
SELECT ename FROM emp WHERE ROWNUM < 10;
n := 1;
LOOP FETCH names_cur BULK COLLECT INTO happyfamily LIMIT 1000;
FOR i IN 1 .. happyfamily.COUNT LOOP
dbms_output.put_line( happyfamily (i));
EXIT WHEN happyfamily.COUNT=0;