日期:2014-05-16  浏览次数:20465 次

oracle 查看锁表用户以及清楚锁信息
  1. SELECT?OS_USER_NAME,??
  2. OBJECT_NAME,??
  3. SESSION_ID,??
  4. SERIAL#??
  5. FROM?V$LOCKED_OBJECT,?USER_OBJECTS,?V$SESSION??
  6. WHERE?V$LOCKED_OBJECT.OBJECT_ID?=?USER_OBJECTS.OBJECT_ID??
  7. AND?V$LOCKED_OBJECT.SESSION_ID?=?V$SESSION.SID??

查看 是否 存在 锁表信息

查询到的SESSION_ID和SERIAL#执行

[sql] view plaincopy
  1. ALTER???SYSTEM???KILL???SESSION??'48,2476'--(48为SESSION_ID的值,?2476为SERIAL#的值)?