2026-03-12 21:01:38
This commit is contained in:
43
tiddlywiki/ASH - examples.txt
Executable file
43
tiddlywiki/ASH - examples.txt
Executable file
@@ -0,0 +1,43 @@
|
||||
col SAMPLE_TIME for a21
|
||||
col Mb for 999 999 999
|
||||
|
||||
select
|
||||
SAMPLE_TIME
|
||||
,SQL_ID
|
||||
,SESSION_ID
|
||||
,PGA_ALLOCATED/1024/1024 Mb
|
||||
,TEMP_SPACE_ALLOCATED/1024 Mb
|
||||
from
|
||||
DBA_HIST_ACTIVE_SESS_HISTORY
|
||||
where
|
||||
SAMPLE_TIME between to_date('2020-05-16 11:00','YYYY-MM-DD HH24:MI') and to_date('2020-05-16 12:00','YYYY-MM-DD HH24:MI')
|
||||
order by
|
||||
SAMPLE_TIME asc
|
||||
/
|
||||
|
||||
|
||||
|
||||
select
|
||||
max(PGA_ALLOCATED/1024/1024) Mb
|
||||
, max(TEMP_SPACE_ALLOCATED/1024) Mb
|
||||
from
|
||||
DBA_HIST_ACTIVE_SESS_HISTORY
|
||||
where
|
||||
SAMPLE_TIME between sysdate-14 and sysdate
|
||||
/
|
||||
|
||||
|
||||
select
|
||||
SAMPLE_TIME
|
||||
,SQL_ID
|
||||
,SESSION_ID
|
||||
,PGA_ALLOCATED/1024/1024 Mb
|
||||
,TEMP_SPACE_ALLOCATED/1024 Mb
|
||||
from
|
||||
DBA_HIST_ACTIVE_SESS_HISTORY
|
||||
where
|
||||
SAMPLE_TIME between sysdate-14 and sysdate
|
||||
and PGA_ALLOCATED is not null
|
||||
order by
|
||||
4 asc
|
||||
/
|
||||
Reference in New Issue
Block a user