重庆思庄Oracle、Redhat认证学习论坛

 找回密码
 注册

QQ登录

只需一步,快速开始

搜索
查看: 925|回复: 0
打印 上一主题 下一主题

ORA-01002: fetch out of sequence

[复制链接]
跳转到指定楼层
楼主
发表于 2016-7-10 14:34:44 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
ORA-01002: fetch out of sequence
Cause: This error means that a fetch has been attempted from a cursor which is no
longer valid. Note that a PL/SQL cursor loop implicitly does fetches, and thus
may also cause this error. There are a number of possible causes for this error,

including: 1) Fetching from a cursor after the last row has been retrieved and the
ORA-1403 error returned. 2) If the cursor has been opened with the FOR UPDATE
clause, fetching after a COMMIT has been issued will return the error. 3)
Rebinding any placeholders in the SQL statement, then issuing a fetch before
reexecuting the statement.
Action: 1) Do not issue a fetch statement after the last row has been retrieved -
there are no more rows to fetch. 2) Do not issue a COMMIT inside a fetch loop for
a cursor that has been opened FOR UPDATE. 3) Reexecute the statement after
rebinding, then attempt to fetch again.

分享到:  QQ好友和群QQ好友和群 QQ空间QQ空间 腾讯微博腾讯微博 腾讯朋友腾讯朋友
收藏收藏 支持支持 反对反对
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|手机版|小黑屋|重庆思庄Oracle、Redhat认证学习论坛 ( 渝ICP备12004239号-4 )

GMT+8, 2024-11-1 13:22 , Processed in 0.104582 second(s), 24 queries .

重庆思庄学习中心论坛-重庆思庄科技有限公司论坛

© 2001-2020

快速回复 返回顶部 返回列表