Philip Howe’s Oracle Blog

Just another WordPress.com weblog

Archive for June, 2022

Who is using all my temp space?

Posted by philiphowe on June 24, 2022

SELECT a.username, a.sid, a.serial#, a.osuser, b.tablespace, b.blocks, c.sql_text
FROM v$session a, v$tempseg_usage b, v$sqlarea c
WHERE a.saddr = b.session_addr
AND c.address= a.sql_address
AND c.hash_value = a.sql_hash_value
ORDER BY b.tablespace, b.blocks;

Thank you.

Posted in 19c | Leave a Comment »

Archive Logs Generated in a Day

Posted by philiphowe on June 10, 2022

This is just one of those questions I get asked from customers, not regularly, but frequently, however, not frequently enough to remember where I put the script………

SELECT trunc(completion_time) TIME, sum(blocks * block_size)/1024/1024/1024 SIZE_GB
FROM v$archived_log
GROUP BY trunc (completion_time)
ORDER BY 1;

Posted in Database, RMAN | Tagged: , , , , | Leave a Comment »