试试用嵌套表:
type tssn is table of number(10);
type tfname is table of varchar2(50);....FOR singleclient IN client_cur
LOOP
ssn.extend;
fname.extend;
ssn(percount) := singleclient.clientid;
fname(percount) := singleclient.clientname;
dbms_output.put_line(ssn(percount));
percount := percount + 1;
END LOOP;
type tssn is table of number(10);
type tfname is table of varchar2(50);....FOR singleclient IN client_cur
LOOP
ssn.extend;
fname.extend;
ssn(percount) := singleclient.clientid;
fname(percount) := singleclient.clientname;
dbms_output.put_line(ssn(percount));
percount := percount + 1;
END LOOP;
我照着如你所写的改了两个地方后,编译没问题,但是使用的时候:
ORA-06531: 引用未初始化的集合还有其他的地方需要修改吗?谢谢!