ERROR- These segments will fail during NEXT EXTENT (DBA_SEGMENTS)

column Tablespaces format a30
column Segment format a40
column "NEXT Needed" format 999,999,999
column "MAX Available" format 999,999,999
select a.tablespace_name "Tablespaces",
 a.owner "Owner",
 a.segment_name "Segment",
 a.next_extent "NEXT Needed",
 b.next_ext "MAX Available"
 from sys.dba_segments a,
 (select tablespace_name,max(bytes) next_ext
 from sys.dba_free_space 
 group by tablespace_name) b
 where a.tablespace_name=b.tablespace_name(+)
 and b.next_ext < a.next_extent;

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: