Check what are sessions doing


select s.sid sid,
s.serial# sh,
s.process pid,
decode(s.status, 'INACTIVE', 'N', 'Y') ia,
decode(sw.wait_time, 0, 'Y', 'N') iw,
decode(sw.wait_time,
0,
sw.seconds_in_wait,
sw.seconds_in_wait - sw.wait_time / 100) secs,
sw.event event,
decode(sq.sql_text, null, ' - Not Available - ', sq.sql_text) sql,
s.USERNAME,
s.MACHINE
from v$session_wait sw, v$session s, v$sql sq
where s.sid = sw.sid
and s.sql_hash_value = sq.hash_value(+)
--   and s.program like '%...program....%'
and upper(sq.sql_text) not like '%CONFIGURATION%'
order by sid

Leave a Reply

Your email address will not be published. Required fields are marked *