oracle日常命令

---查询锁表(查出后,再执行查询结果进行释放;可多次查询,存在循环锁表的情况)--

select 'alter system kill session '|| ''''|| sess.sid || ',' || sess.serial# || ''''|| ';'
from v$locked_object lo,
dba_objects ao,
v$session sess
where ao.object_id = lo.object_id and lo.session_id = sess.sid;

posted @ 2021-10-28 17:25  Deng0727  阅读(43)  评论(0编辑  收藏  举报