Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: top sessions ?
You can use this join:
select username, terminal, name, value
from v$statname n,
v$session s,
v$sesstat t
where s.sid=t.sid
and n.statistic# = t.statistic# and s.type = 'USER' and s.username is not NULL and n.name = 'session pga memory' and t.value > &use_at_least_30000 +--------------------------------------------------------------------------+ | Vitaliy Mogilevskiy | Senior Consultant | CORE Technology Group, Inc. | E-mail: vit100gain_at_earthlink.net | Web Page: http://home.earthlink.net/~vit100gain/index.html | *** Free DBA Script Library at my Web Page *** |
+--------------------------------------------------------------------------+
Jan-Marten Spit wrote:
> Hi yall,
>
> How would you determine the top N sessions on an Oracle instance (using
> V$SESSTAT)
>
> Will looking at the consistent gets (statistic# 39) give an accurate
> picture?
>
> for example,
>
> select
> sid,
> value
> from
> v$sesstat
> where
> statistic#=39
> order by value desc
>
> Any ideas for a formula combining statistics from V$SESTAT that gives an
> accurate picture?
>
> Read you,
>
> Jan-Marten Spit
-- Received on Tue Apr 06 1999 - 12:40:10 CDT