Individuare Tabelle in Lock
Per individuare la sessione in attesa select * from V$SESSION_WAIT where EVENT = 'enqueue'; SID identifier of session holding the lock P1, P2, P3 determine the resource when event = 'enqueue' SECONDS_IN_WAIT gives how long the wait did occurs SELECT substr(DECODE(request,0,'Holder: ','Waiter: ')||sid,1,17) sess,id1, id2, lmode, request, type, inst_id FROM GV$LOCK WHERE (id1, id2, type) IN (SELECT id1, id2, type FROM GV$LOCK WHERE request>0) ORDER BY id1, request Per individuare la sessione bloccante e quindi che trattiene le risorse select * from v$lock where block=1; select sid, serial#, username from v$session where sid in (select blocking_session from V$Session ); sid, serial# sono gli identificativi della sessione oracle LOCKWAIT address of the lock waiting, otherwise null ROW_WAIT_OBJ# object identified of the object we are waiting on (object_id of dba_objects) ROW_WAIT_FILE#, ROW_WAIT_BLOCK#, ROW_WAIT_ROW# sono i file_id , block_id and