ORACLE 错误:oralce record is locked by another user

时间:2022-07-07 17:09:59
 方法/步骤
 
  1.  

    打开PL/SQL客户端,然后修改表记录中的数据,提交修改,如下提示

  2. 2

    我们关闭异常警告窗口,在执行sql的窗口中输入如下命令:select t2.username,t2.sid,t2.serial#,t2.logon_time from v$locked_object t1,v$session t2 where t1.session_id=t2.sid ; 这个sql语句是关于查看锁的

    ORACLE 错误:oralce record is locked by another user
  3. 3

    上面的图 我已经解锁了,如果没有解锁,每个列都会有值,例如sid为1871,serial#的值为18798,然后执行命令:alter system kill session 'sid,serial#'; 也就是:alter system kill session '1871,18798';

    ORACLE 错误:oralce record is locked by another user
  4. 4

    执行完毕之后,我们在修改数据,提交,就不会报被锁定的警告了

    ORACLE 错误:oralce record is locked by another user