Sunday, August 16, 2015

Oracle : Script to report the storage parameters of the tablespaces in a database

COL   stat   FORM A7         HEAD   'Status'      JUST c
COL   name   FORM A15        HEAD 'Tablespace'    JUST c
COL   init   FORM 999,990    HEAD 'Initial|(KB)'  JUST c
COL   next   FORM 999,990    HEAD 'Next|(KB)'     JUST c
COL   pcti   FORM 990        HEAD 'Pct|incr'      JUST c
COL   minx   FORM 990        HEAD 'Min|exts'      JUST c
COL   maxe   FORM 9999999990 HEAD 'Max|exts'      JUST c

BREAK ON stat SKIP 1

SELECT status    stat, tablespace_name     name,initial_extent/1024   init,
 next_extent/1024      next, pct_increase       pcti,min_extents  minx,
 max_extents           maxe
FROM dba_tablespaces WHERE status!='INVALID'
ORDER BY 1,2

No comments:

Post a Comment