![]() |
|
SQL ScriptTablespace Mapper |
|
This script lists all used and free extents of a given tablespace. This is an easy way to see tablespace fragmentation.
tspace - The Tablespace to Map.
REM Copyright (C) Think Forward.com 1998- 2005. All rights reserved.
set pages 60 set lines 132 set ver off col owner form a10 col file_id form 9999 heading "File ID" col block_id form 9999999 heading "Block ID" ACCEPT tspace prompt 'Enter Tablespace Name : ' spool mapper.lst select 'FREE SPACE' owner , ' ' object , file_id , block_id , bytes from dba_free_space where tablespace_name = UPPER('&tspace') union select SUBSTR(owner,1,20) , SUBSTR(segment_name,1,32) , file_id , block_id , bytes from dba_extents where tablespace_name = UPPER('&tspace') order by 3,4 / spool off
Return to Index of SQL Scripts
General Information :
Home | Company Profile
| Contact Us | Legal
Database Support :
Proactive Support
|
Pay Per Incident Support
Expert Services :
High Availability
|
Creative Solutions
|
Training
Build Services :
Oracle Installations
|
Revive your Oracle Setup
|
Low Cost Development
Free Oracle Resources:
DBA Scripts
|
Oracle Links