|
Re: ORA-00054 resource busy and acquire with NOWAIT specified [message #58104 is a reply to message #58101] |
Thu, 31 July 2003 00:03 |
Vikas Gupta
Messages: 115 Registered: February 2002
|
Senior Member |
|
|
The table you are trying to access or update has been locked by another user and hence this error.
I use the following scripts:
1. Identify USERS who are locked in the system:
select b.username, b.serial#, d.id1, a.sql_text
from v$session b, v$lock d, v$sqltext a
where b.lockwait = d.kaddr
and a.address = b.sql_address
and a.hash_value = b.sql_hash_value;
2. Who is locking the USERS:
select a.serial#, a.sid, a.username, b.id1,
c.sql_text from
v$session a, v$lock b, v$sqltext c
where b.id1 in
(select distinct e.id1 from v$session d,
v$lock e where d.lockwait = e.kaddr)
and a.sid = b.sid
and c.hash_value = a.sql_hash_value
and b.request = 0;
3. Finally Kill the USER :
alter system Kill session ... pass parameters
serial#, sid from the 2nd step.
Regards,
Vikas.
|
|
|
|