oracle-----list,array
定义type idList_type is table of emp.id%type;type namelist_type is table of emp.name%type;idlist idlist_type; namelist namelist_type;begin open emp_cv for select id,name from emp; fetch emp_cv bulk collect into idlist,namelist; //这个语句一次性就放入了 close emp_cv; for i in idlist.first .. idlist.last loop dbms_output.put_line(idlist(i)); end loop;end;