首页 > Linux操作系统 > Linux操作系统 > ORA-01555 和游标

ORA-01555 和游标

原创 Linux操作系统 作者:gaopengtttt 时间:2012-03-23 09:49:47 0 删除 编辑
This is the situation when a query opens a cursor, then loops through fetching, changing, and committing the records on the same table. In this scenerio, very often an ORA-01555 can result. Let's take the  following example to explain this:

A cursor was opened at SCN=10. The execution SCN of the query is  then marked as SCN=10. Every fetch by that cursor now needs to get the read-consistent data from SCN=10. The user program is now  fetching x numbers of records, changing them, and committing them. Let's say they were committed with SCN=20. If a later fetch happens to retrieve a record which is in one of the previously committed  blocks, then the fetch will see that the SCN there as 20. Since the fetch has to get the snapshot from SCN=10 it will try to find it in the rollback segments. If it could rollback sufficiently backwards  as previously explained, then it could reconstruct the snapshot  from SCN=10. If not, then it will result in an ORA-01555 error.

来自 “ ITPUB博客 ” ,链接:,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
wxh gp_22389860


  • 博文量
  • 访问量