Skip to content
pvmehta.com

pvmehta.com

  • Home
  • About Me
  • Toggle search form
  • AWR license Oracle
  • find_arc.sql Oracle
  • Changing default shell Linux/Unix
  • Oracle10g – Using SQLAccess Advisor (DBMS_ADVISOR) with the Automatic Workload Repository Oracle
  • sess_server.sql Oracle
  • Explain Plan Output 2 Oracle
  • export import with parameter file. Oracle
  • Pending Distributed Transations Oracle
  • oracle 11g RAC on vmware Oracle
  • All About oracle password and security from metalink Oracle
  • column level grant syntax Oracle
  • To see how much time or progress of long transaction Oracle
  • scripts to take listener.log backup Linux/Unix
  • 751131.1 New Article Error 2819 While Requesting a Systemstate Dump Oracle
  • How to specify 2 arch location to avoid any kind of DB hanging. Oracle

temp_use.sql diplays usage of temp ts

Posted on 10-May-2008 By Admin No Comments on temp_use.sql diplays usage of temp ts

SELECT b.TABLESPACE,

b.segfile#,

b.segblk#,

b.blocks,

a.SID,

a.serial#,

a.username,

a.osuser,

a.status,

c.sql_text

FROM v$session a,

v$sort_usage b,

v$sqlarea c

WHERE a.saddr = b.session_addr

AND a.SQL_HASH_VALUE = c.HASH_VALUE

ORDER BY b.TABLESPACE, b.segfile#, b.segblk#, b.blocks

/

set pagesize 10000

set linesize 133

column tablespace format a15 heading ‘Tablespace Name’

column segfile# format 9,999 heading ‘File|ID’

column segblk# format 999,999,999 heading ‘Block|ID’

column blocks format 999,999,999 heading ‘Blocks’

column username format a15

select

b.tablespace, b.segfile#, b.segblk#, b.blocks,

a.sid, a.serial#, a.username, a.osuser, a.status

from v$session a, v$sort_usage b

where a.saddr = b.session_addr

order by b.tablespace,b.segfile#,b.segblk#,b.blocks;

Oracle, SQL scripts

Post navigation

Previous Post: get_ratio.sql get the ratio of users from v$session and this uses CASE-WHEN-THEN clause
Next Post: send attachment from unix-shell script

Related Posts

  • New Latest Param.sql for finding all hidden parameters also Oracle
  • find_string_in_database.sql Oracle
  • Rownum with Order by Oracle
  • export import with parameter file. Oracle
  • Database link password in user_db_links Oracle
  • Settting up get_vmstat.sh for colletinf CPU Usage. Oracle

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Categories

  • Ansible (0)
  • AWS (2)
  • Azure (1)
  • Django (0)
  • GIT (1)
  • Linux/Unix (149)
  • MYSQL (5)
  • Oracle (400)
  • PHP/MYSQL/Wordpress (10)
  • POSTGRESQL (1)
  • Power-BI (0)
  • Python/PySpark (7)
  • RAC (18)
  • rman-dataguard (26)
  • shell (150)
  • SQL scripts (348)
  • SQL Server (6)
  • Uncategorized (3)
  • Videos (0)

Recent Posts

  • Running PDB on single node in RAC09-Apr-2026
  • find_arc.sql09-Apr-2026
  • pvm_pre_change.sql08-Apr-2026
  • find_encr_wallet.sql08-Apr-2026
  • find_pdbs.sql08-Apr-2026
  • Creating a Container Database using dbaascli08-Apr-2026
  • track_autoupgrade_copy_progress.sql01-Apr-2026
  • refre.sql for multitenant01-Apr-2026
  • prepfiles.sh for step by step generating pending statistics files10-Mar-2026
  • tracksqltime.sql05-Mar-2026

Archives

  • 2026
  • 2025
  • 2024
  • 2023
  • 2010
  • 2009
  • 2008
  • 2007
  • 2006
  • 2005
  • Temporary Tablespsace Temp tablespace behaviour Oracle
  • Finding last recovered file on DR and remove all chanracters before any “/” Linux/Unix
  • Linux CPU info. Linux/Unix
  • Very Good Oralce Internal Tuning Book Oracle
  • Gathering statistics with DBMS_STATS Oracle
  • longtx.sql with the flag whether session is blocking any DML locks or not. Oracle
  • move_arch_files.ksh Linux/Unix
  • Kernel Parameters for Solaris Linux/Unix

Copyright © 2026 pvmehta.com.

Powered by PressBook News WordPress theme