例: テーブルfoobarをロックしているsessionを探す
SELECT
object_name,
oracle_username,
s.sid,
s.serial#,
s.logon_time,
sql_address
FROM v$locked_object l,
dba_objects o,
v$session s
WHERE l.OBJECT_ID = o.OBJECT_ID
AND l.SESSION_ID = s.SID
AND object_name = 'foobar'
;
見つけたsessionをkill
ALTER SYSTEM kill session 'sid, serial';