首页 新闻 会员 周边

怎么在PL/sql 中取存储过程的返回值?

0
悬赏园豆:5 [待解决问题]

--建立包
create or replace package sp_mytest as
type c_cursor is ref cursor;
end sp_mytest;
--建立包体
create or replace procedure sp_mypro31
( id number,result out number,c_pcursor out sp_mytest.c_cursor)
is
v_count number(4);
begin
open c_pcursor for select * from dual ;
select id into v_count from dual;
if v_count>0 then result:=0;
else
result:=1;
end if;
end c_pcursor;
end;

建立包体时提示出错

12/5 PLS-00113: END 标识符 'C_PCURSOR' 必须同 'SP_MYPRO31' 匹配 (在第 1 行,第 12 列)
13/1 PLS-00103: 出现符号 "END“  

请教

1 哪出错了?
2怎么在pl/sql developer 中调用取这个 result 和游标的值,需要代码谢谢

易顺金的主页 易顺金 | 初学一级 | 园豆:2
提问于:2013-11-16 23:16
< >
分享
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册