Select t.owner,
t.table_name,
to_char(nvl(sum(s.bytes),0) / 1024 / 1024 , ‘9999999.99’) mb
from dba_tables t,
dba_segments s
where –t.table_name not like ‘DECOM_%’ escape ‘\’ — does not start with decom_
— t.owner = :schema
s.owner(+) = t.owner
and s.segment_name(+) = t.table_name
and nvl(s.bytes,0) > 10000000
group by t.owner, t.table_name
order by 2 desc;
select nvl(tablespace_name,’ – Total – ‘) tablespace_name,
round(sum(bytes)/1024/1024/1024,1) as size_in_GB
from dba_segments
where tablespace_name not in (‘SYSAUX’,’SYSTEM’)
group by rollup(tablespace_name)
order by size_in_GB desc;
PURGE RECYCLEBIN;
SELECT * FROM RECYCLEBIN;
SELECT * FROM USER_RECYCLEBIN;
select owner, segment_name, partition_name, populate_status, bytes,
inmemory_size, bytes_not_populated
from v$im_segments
order by owner, segment_name, partition_name;