PROMPT [STEP 10] TEMP/PGA Spill Indicators


-- TEMP usage from AWR (adjust column based on availability)

SELECT ROUND(SUM(NVL(temp_space_allocated_delta, temp_space_allocated))/1024/1024/1024,3) AS temp_gb

FROM   dba_hist_sqlstat

WHERE  sql_id='&sql_id';


-- Current PGA snapshot (runtime; may require privileges)

COLUMN name FORMAT A35

COLUMN value FORMAT 999,999,999,999

SELECT name, value

FROM   v$pgastat

WHERE  name IN ('total PGA allocated','PGA cache hit percentage');

Popular posts from this blog