Skip to content
pvmehta.com

pvmehta.com

  • Home
  • About Me
  • Toggle search form
  • Directory wise folder wise space usage Linux/Unix
  • pvmehta.com SQL scripts
    Find which sessions is accessing object that prevent your session to have exclusive locks in Oracle Oracle
  • Rename Tablespace Oracle
  • Ports used by Oracle Software Oracle
  • Library cahe Latches and internal explaination Oracle
  • Remove DOS CR/LFs (^M) Linux/Unix
  • Process Map for CPU and Memory for OS processes Linux/Unix
  • AWR license Oracle
  • dbinv.sql Oracle
  • Oracle 10g for solaris 10 Oracle
  • Remove duplicate rows from table Oracle
  • executing Function from SQLPLUS prompt Oracle
  • Search and Replace vi editor command. Linux/Unix
  • pvm_rbs1.sql (to collect rbs info from db) Oracle
  • proper cpu stats Linux/Unix

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

  • Configure ssh authentications for RAC Oracle
  • How to check current redo log progress redo_progress.sql Oracle
  • Implementing Listener Security Oracle
  • Find nth max and min. Oracle
  • Goldengate document from Porus Oracle
  • Oracle Data Direct to TAPE Oracle

Leave a Reply Cancel reply

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

Categories

  • Ansible (0)
  • AWS (2)
  • Azure (1)
  • Linux/Unix (149)
  • MYSQL (5)
  • Oracle (392)
  • PHP/MYSQL/Wordpress (10)
  • POSTGRESQL (0)
  • Power-BI (0)
  • Python/PySpark (7)
  • RAC (17)
  • rman-dataguard (26)
  • shell (149)
  • SQL scripts (341)
  • SQL Server (6)
  • Uncategorized (0)
  • Videos (0)

Recent Posts

  • SQL Server Vs Oracle Architecture difference25-Jul-2025
  • SQL Server: How to see historical transactions25-Jul-2025
  • SQL Server: How to see current transactions or requests25-Jul-2025
  • T-SQL Vs PL/SQL Syntax25-Jul-2025
  • Check SQL Server edition25-Jul-2025
  • Checking SQL Server Version25-Jul-2025
  • Oracle vs MYSQL Architecture differences (For DBAs)24-Jul-2025
  • V$INSTANCE of Oracle in MYSQL24-Jul-2025
  • Day to day MYSQL DBA operations (Compared with Oracle DBA)24-Jul-2025
  • MYSQL and Oracle Comparison for Oracle DBA24-Jul-2025

Archives

  • 2025
  • 2024
  • 2023
  • 2010
  • 2009
  • 2008
  • 2007
  • 2006
  • 2005
  • Import and export statements Oracle
  • Rman Notes -1 Oracle
  • ipcs -l Linux/Unix
  • Good Site for Oracle Internals Oracle
  • Facts about SCN and Rollback Segment Oracle
  • Jai Shree Ram Oracle
  • export import with parameter file. Oracle
  • Good links for x$ tables in oracle. Oracle

Copyright © 2025 pvmehta.com.

Powered by PressBook News WordPress theme