Pages

Thursday, September 28, 2023

SQL Net* break message

SQL Net* break message

SELECT S.LOGON_TIME, --s.LAST_CALL_ET "idel in sec", floor(s.LAST_CALL_ET/86400) || 'd ' || to_char(to_date(mod  (s.LAST_CALL_ET,86400) ,'sssss'),'hh24"h" mi"m" ss"s"') "Idle Time", S.username,S.sid,S.serial#,S.status,S.program,S.module,  s.machine, s.event, 'alter system kill session ' ||''''||s.sid||','||s.serial#||''''||'  IMMEDIATE;' Kill_Stmt --,'alter system kill session ' ||''''||s.sid||','||s.serial#||',@'||inst_id||''''||'  IMMEDIATE;' Kill_Stmt FROM gV$SESSION SWHERE 1=1 --  and S.logon_time  <sysdate  --   and s.type='USER' and s.status<> 'ACTIVE' --and s.LAST_CALL_ET>86400/48 --and s.event='SQL*Net break/reset to client' --and( s.machine = 'anb-srl-ogcoms.anb,net' or  s.terminal ='anb-srl-ogcoms.anb.net') ORDER BY 2 desc;

No comments:

Post a Comment