white knight

导航

 
select * from v$db_object_cache where locks > 0 and pins > 0 and type='PROCEDURE';

select   b.sid,b.SERIAL#,a.OBJECT, 'alter system kill session   ' || '''' || b.sid || ',' ||b.SERIAL# ||  ''';' kill_command
               from   SYS.V_$ACCESS a, SYS.V_$session b
               where    a.type = 'PROCEDURE'
                  and   (a.OBJECT like upper('%PROCEDURE_NAME%') or
                            a.OBJECT like lower('%PROCEDURE_NAME%'))
                 and a.sid = b.sid
                 and b.status = 'ACTIVE';

alter system kill session   '171,13';
posted on 2018-03-26 11:06  white knight  阅读(3016)  评论(0编辑  收藏  举报