Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Locks
On Sat, 12 Sep 1998 calberto_at_my-dejanews.com wrote:
> How can I identify which user is holding(locking) resources that another user
> wants to use? I have queried V$LOCKED_OBJECT but it shows all the tables some
> user is locking, regardless if another is trying to access it at the same
> time or not. I only want to know if some user is waiting (being blocked) for
> another user. Is there any status in any of these dictionary tables, like
> V$LOCKED_OBJECT, V$LOCK and V$SESSION.
To find the blocker, someone (obviously) must be waiting on the enqueue.
select s.sid, osuser, client_info, etc..
from v$session s, v$lock l
where s.sid = l.sid
and block = 1;
OR...
select sid from v$lock where block = 1;
--
Jeremiah Wilton http://www.wolfenet.com/~jeremiah
Received on Tue Sep 15 1998 - 00:25:53 CDT