Oracle ref 动态游标
Oracle ref 动态游标:
create or replace procedure pro_cursor_type_V
as
t_tmp table3%rowtype;
type c_type is ref cursor;
cur c_type;
v_taname varchar2(100);
begin
v_taname:='aa';
open cur for 'select * from table3 where taname=:a order by taid desc' --a只是绑定变量的占位符以 =: 符号进行绑定
using v_taname;
dbms_output.put_line('名称有');
loop
fetch cur into t_tmp;
exit when cur%notfound;
dbms_output.put_line('名称为'||t_tmp.taname||'日期为:'||t_tmp.indate);
end loop;
end pro_cursor_type_V;
相关推荐
人勤阡陌绿 2019-03-27
jchunwen 2011-09-22
joyleeLyhua 2013-08-13
Hody 2015-07-31
landdin0 2010-01-17
zgxzowen 2009-04-02
lmrdaydayup 2015-05-01
iilegend 2015-01-08
程序艺术 2014-06-22
大慧 2013-01-13
LinuxOracleWf 2012-06-22
oracleerp 2011-09-08
oracle 2011-06-25
oracleerp 2010-12-13