Query to find and remove Oracle database locks

Query to find and remove Oracle database locks
Oracle database locks
oracle lock table
blocking session in oracle
oracle deadlock
oracle lock
oracle locked objects
query to check locks in oracle database
oracle table lock query
oracle show locks
find blocking session in oracle
oracle db lock
oracle check locks
query to find locked objects in oracle
oracle check table lock
How to find the Oracle database locks
How to remove locks from Oracle database

-- Use below query to find locked objects
select
c.owner,
c.object_name,
c.object_type,
b.sid,
b.serial#,
b.status,
b.osuser,
b.machine
from
v$locked_object a ,
v$session b,
dba_objects c
where
b.sid = a.session_id
and
a.object_id = c.object_id;


--use below query to kill the blocking session

ALTER SYSTEM KILL SESSION '1398,21328' --SID and SERIAL# from above query

--
Related posts: Upload your own post and refer it anywhere anytime:

Leave a Reply