修改或删除一个global temporary table这样的表时报ORA-14450: 试图访问已经在使用的事务处理临时表,根据网上文章提供的方法,问题是解决了..
http://hi.baidu.com/sandy_zjw/item/ed0899ed82cb34d5ea34c991
--1、查找sessionID
select SID,SERIAL# from V$session where SID in (select sid from v$enqueue_lock t where t.type='TO')
SID SERIAL#
-------------------------
103 257
113 181
124 89
126 632
--2、kill session
select 'alter system kill session '''||a.sid||','||a.SERIAL#||''';' from V$session a
where SID in (SELECT SID FROM v$enqueue_lock t WHERE t.type='TO');
alter system kill session '103,257';
alter system kill session '113,181';
alter system kill session '124,89';
alter system kill session '126,632';
---------------------
-- select * from v$enqueue_lock t where t.type='TO'
-- select * from v$lock_type where type in ('AE','TO');
--3,运行上面返回的sql
alter system kill session '103,257';
alter system kill session '113,181';
alter system kill session '124,89';
alter system kill session '126,632';
--至此结束
有点不明白,这些操作的详细意思什么,大概就是把数据库里的session都kill了,但我现在是修改或删除一个global temporary table这样的表时出的这个错,应该只针对这个表的session kill了就行,不知道要怎样做呢?大师们详解...
http://hi.baidu.com/sandy_zjw/item/ed0899ed82cb34d5ea34c991
--1、查找sessionID
select SID,SERIAL# from V$session where SID in (select sid from v$enqueue_lock t where t.type='TO')
SID SERIAL#
-------------------------
103 257
113 181
124 89
126 632
--2、kill session
select 'alter system kill session '''||a.sid||','||a.SERIAL#||''';' from V$session a
where SID in (SELECT SID FROM v$enqueue_lock t WHERE t.type='TO');
alter system kill session '103,257';
alter system kill session '113,181';
alter system kill session '124,89';
alter system kill session '126,632';
---------------------
-- select * from v$enqueue_lock t where t.type='TO'
-- select * from v$lock_type where type in ('AE','TO');
--3,运行上面返回的sql
alter system kill session '103,257';
alter system kill session '113,181';
alter system kill session '124,89';
alter system kill session '126,632';
--至此结束
有点不明白,这些操作的详细意思什么,大概就是把数据库里的session都kill了,但我现在是修改或删除一个global temporary table这样的表时出的这个错,应该只针对这个表的session kill了就行,不知道要怎样做呢?大师们详解...