zoukankan      html  css  js  c++  java
  • 052-172

    The session of user SCOTT receives the following error after executing an UPDATE command on
    the EMP table:
    ERROR at line 1:
    ORA-00060: deadlock detected while waiting for resource
    On investigation, you find that a session opened by user JIM has a transaction that caused the deadlock.
    Which two statements are true regarding the session of SCOTT in this scenario? (Choose two.)
    A.The session is terminated after receiving the error and JIM can continue with his transaction.
    B.SCOTT should perform a COMMIT or ROLLBACK to allow JIM to continue with his transaction.
    C.The session is rolled back after receiving the error and JIM can continue with his transaction.
    D.SCOTT has to reexecute the last command in the transaction after he commits the transaction.

    死锁相关 https://www.cnblogs.com/kerrycode/p/6928263.html 
      死锁是锁定冲突的特殊示例。两个或多个会话等待由对方锁定的数据时,就会发生死锁。因为每个会话都在等待另一个会话释放锁定,所以任何一个会话都不能完成事务处理,也不能解决冲突。 Oracle 数据库会自动检测死锁并终止语句,同时显示错误消息。更正这种错误的适当做法是执行提交或回退,这样做会在一个会话中释放任何其它锁定,以便其它会话可继续完成其事务处理。 scott 必须提交或回退,才能更正检测到的死锁误。如果执行提交,则必须重新提交第二次更新才能完成事务处理。如果执行回退,则必须同时重新提交这两个语句才能完成事务处理。

  • 相关阅读:
    线段树
    5709 01背包
    JavaEE Tutorials (19)
    洛谷 P3385 【模板】负环
    洛谷 P3388 【模板】割点(割顶)
    洛谷 P3387 【模板】缩点
    洛谷 P3386 【模板】二分图匹配
    洛谷 P3371 【模板】单源最短路径
    洛谷 P3370 【模板】字符串哈希
    洛谷 P3366 【模板】最小生成树
  • 原文地址:https://www.cnblogs.com/Babylon/p/8041996.html
Copyright © 2011-2022 走看看