Friday, 30 May 2014

How to find INACTIVE Sessions for more than 1 hour in Oracle database

How to find INACTIVE Sessions for more than 1 hour in Oracle database

SELECT round(last_call_et/60), username, osuser, module,  program, logon_time
FROM v$session
WHERE type       = 'USER'
AND status       = 'INACTIVE'
AND last_call_et > 3600
order by last_call_et desc;