REM REM DBAToolZ NOTE: REM This script was obtained from DBAToolZ.com REM It's configured to work with SQL Directory (SQLDIR). REM SQLDIR is a utility that allows easy organization and REM execution of SQL*Plus scripts using user-friendly menu. REM Visit DBAToolZ.com for more details and free SQL scripts. REM REM REM File: REM s_db_segs_all.sql REM REM SEGMENT STORAGE TABSP INDX TAB REM REM Author: REM Vitaliy Mogilevskiy REM VMOGILEV REM (vit100gain@earthlink.net) REM REM Purpose: REM REM This script gives general idea of segments and extents REM in a database for all the tablespaces REM REM REM Usage: REM s_db_segs_all.sql REM REM Example: REM s_db_segs_all.sql REM REM REM History: REM 08-01-1998 VMOGILEV Created REM REM set lines 132 set pages 90 break on tablespace_name skip 1 compute sum of sum(bytes)/1024/1024 sum(extents) on tablespace_name col count(*) format 99999999 heading "Number Of|Segments" col sum(extents) format 99999999 heading "Number Of|Extents" col sum(bytes)/1024/1024 format 999,999.99 heading "Total|Size MB" select tablespace_name , segment_type , count(*) , sum(extents) , sum(bytes)/1024/1024 from dba_segments group by segment_type , tablespace_name order by tablespace_name, segment_type /