by http://webgeektutorials.blogspot.com

Monday, May 14, 2012

Oracle DBA Script : Detect Possible next extent failures

Script: 


Select
substr(sg.tablespace_name,1,30)Tablespace,
substr(sg.segment_name,1,30) Object,
sg.extents extents,
sg.next_extent next,
max(sp.bytes) available
From dba_free_space sp, dba_segments sg
Where sp.tablespace_name = sg.tablespace_name
Having max(sp.bytes) < sg.next_extent
Group by sg.tablespace_name,
sg.segment_name, sg.extents, sg.next_extent
Order by 1,2;

No comments:

Post a Comment