The resource is busy, but specify NOWAIT to get the resource, or the timeout fails

1. Problem description

 今天在oracle数据库进行删除操作时,一直爆出' 资源正忙, 但指定以 NOWAIT 方式获取资源, 或者超时失效' 的提示

   
   
    
    
  • 1

Two solutions

1. Query the locked current session id, the sql statement is as follows

select session_id from v$locked_object;
insert image description here

2. Query the detailed information of the current session, the sql statement is as follows

SELECT sid, serial#, username, osuser FROM v$session where sid = 99;

SELECT sid, serial#, username, osuser FROM v$session where sid = 136;
insert image description here

3. Close the current session.

ALTER SYSTEM KILL SESSION ‘136,56320’;

ALTER SYSTEM KILL SESSION ‘99,11076’;

1. Problem description

 今天在oracle数据库进行删除操作时,一直爆出' 资源正忙, 但指定以 NOWAIT 方式获取资源, 或者超时失效' 的提示

   
   
  
  
  • 1

Two solutions

1. Query the locked current session id, the sql statement is as follows

select session_id from v$locked_object;
insert image description here

2. Query the detailed information of the current session, the sql statement is as follows

SELECT sid, serial#, username, osuser FROM v$session where sid = 99;

SELECT sid, serial#, username, osuser FROM v$session where sid = 136;
insert image description here

3. Close the current session.

ALTER SYSTEM KILL SESSION ‘136,56320’;

ALTER SYSTEM KILL SESSION ‘99,11076’;

Guess you like

Origin blog.csdn.net/Hx230/article/details/124156221