[b]解决oracle不能for update[/b]
select * from table_Name for update 造成Oracle数据库卡死
1:首先查找出问题表的session ID
select SESSION_ID from v$locked_object l join dba_objects o on (l.OBJECT_ID=o.object_id) where o.object_name='table_name'
2:查看这个session的情况
select * from v$session where sid=94;
142就是我第一步查询出来的session ID,并找出 OSUSER,MACHINE,PROGRAM 等字段,就能查出是不是自己的客户端
select OSUSER, MACHINE, PROGRAM from v$session where sid=94;
3:确定是自己的客户端后杀死它
alter system kill session 'sid,serial#';
select * from table_Name for update 造成Oracle数据库卡死
1:首先查找出问题表的session ID
select SESSION_ID from v$locked_object l join dba_objects o on (l.OBJECT_ID=o.object_id) where o.object_name='table_name'
2:查看这个session的情况
select * from v$session where sid=94;
142就是我第一步查询出来的session ID,并找出 OSUSER,MACHINE,PROGRAM 等字段,就能查出是不是自己的客户端
select OSUSER, MACHINE, PROGRAM from v$session where sid=94;
3:确定是自己的客户端后杀死它
alter system kill session 'sid,serial#';