declare
cursor rowList(c_name varchar2,c_id number) is
select * from t b where b.name = c_name and b.id = c_id;
(v_rowValue varchar2(20);)。
rowValue t%rowtype;
begin
open rowList('傻B', 2);
cursor rowList(c_name varchar2,c_id number) is
select * from t b where b.name = c_name and b.id = c_id;
(v_rowValue varchar2(20);)。
rowValue t%rowtype;
begin
open rowList('傻B', 2);
loop
fetch rowList
into rowValue;
fetch rowList
into rowValue;
exit when rowList%notfound;
dbms_output.put_line(rowValue.name);
end loop;
close rowList;
close rowList;
end;
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/25989950/viewspace-716903/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/25989950/viewspace-716903/