数据库表被锁,检查和解锁笔记

查被锁的表
select
 object_name, machine, s.sid, s.serial#
  from 
  v$locked_object l, dba_objects o, v$session s
 where l.object_id = o.object_id
   and l.session_id = s.sid;
解除被锁的表
alter system kill session '9,15706' immediate;  //对应sid和seriale

你可能感兴趣的:(数据库表被锁,检查和解锁笔记)