注意:必须有Oracle DBA 权限才能操作一下SQL语句:
---查询锁定的会话
select * from v$session t where t.SID in (select t2.session_id from v$locked_object t2);
---查询锁定的对象
select * from all_objects t1 join v$locked_object t2 on t1.object_id = t2.OBJECT_ID;
---解锁
alter system kill session '[sid],[serial#]'
example:
alter system kill session '706, 233'