在不改init.ora的前提下,如何解决ORA-01000 maximum open cursors exceeded?

offsider 2002-05-10 04:38:45
我的init.ora中open_cursor已经到了1500个了,还是会报这个错误,这种错误是怎么产生的?有没有办法强制释放sql语句的cursor?
...全文
222 13 打赏 收藏 转发到动态 举报
写回复
用AI写文章
13 条回复
切换为时间正序
请发表友善的回复…
发表回复
tfp 2002-07-01
  • 打赏
  • 举报
回复
动态游标如何释放?
declare
t_cur is ref cursor;
begin
rst t_cur ;
sqlview := 'select * from table ';
open rst for sqlview;
/* how to close the rst */
???

end ;
developer2002 2002-07-01
  • 打赏
  • 举报
回复
还是要检查程序,open_cursors再设置多大,程序不关,总没有办法
ATCG 2002-07-01
  • 打赏
  • 举报
回复
动态游标(即游标变量)和静态游标的关闭是一样的,没有区别。
Close Cursor_Name;
3yugui 2002-07-01
  • 打赏
  • 举报
回复
procedure p_CLOSE(
p_dd in out t_cursor)
is
begin
IF P_DD%ISOPEN THEN
CLOSE p_dd;
END IF;
end;
end;
tfp 2002-07-01
  • 打赏
  • 举报
回复
It is a function that will be return a result .
when client application call the function repeat 10000 will taken
error as ORA-01000: maximum open cursors exceeded


how to do ?

tfp 2002-07-01
  • 打赏
  • 举报
回复


please give code , thanks

I use the following code to close , but it not work

eg
if rst%isOpen then
close rst
end if ;


the code never execute why ?

xinpingf 2002-07-01
  • 打赏
  • 举报
回复
学习
blue__star 2002-07-01
  • 打赏
  • 举报
回复
在程序中CLOSE()
或再连接池中控制游标的关闭
thingsfly 2002-05-10
  • 打赏
  • 举报
回复
隐式的cursor会自动关闭的啊。
主要是显示的cursor的关闭。
尤其是在自己定义的过程和函数里。
jlandzpa 2002-05-10
  • 打赏
  • 举报
回复
SDT(众人皆醒我独醉) :可能性很大.
offsider 2002-05-10
  • 打赏
  • 举报
回复
to KingSunSha(弱水三千)
我想知道的就是如何关闭隐式的cursor,显式的cursor很简单,但隐式的我不知道怎么在执行完毕后关闭cursor
KingSunSha 2002-05-10
  • 打赏
  • 举报
回复
请注意:除了是显式定义的cursor,还要注意隐式cursor,一句select ...就是一个隐式cursor。所以请检查你的代码。
SDT 2002-05-10
  • 打赏
  • 举报
回复
是不是在程序中忘了close,否则应该能满足啊。
建议检查程序,在异常处理中记得close。

2,596

社区成员

发帖
与我相关
我的任务
社区描述
Sybase相关技术讨论区
社区管理员
  • Sybase社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧