select SID,WAIT_TIME,SECONDS_IN_WAIT,STATE,event from gv$session_wait where sid= 661
select
SID,
EVENT,
sum(TOTAL_WAITS),
sum(TOTAL_TIMEOUTS),
sum(TIME_WAITED),
sum(AVERAGE_WAIT),
MAX_WAIT
from gV$SESSION_EVENT
where sid=661
group by SID,EVENT,MAX_WAIT;
/*----- waits oracle ------*/
select a.sid,
b.username,
a.wait_class,
a.total_waits,
round((a.time_waited / 100),2) time_waited_secs
from sys.v_$session_wait_class a,
sys.v_$session b
where b.sid = a.sid and
b.username is not null and
a.wait_class != 'Idle' and
a.sid='578'
order by 5 desc;