How to identify wasted space/free space for all tables?
As the title goes, is there anyway for me to gather a report of which tables have alot of free space / wasted space?
Currently I'm using DBMS_SPACE.SPACE_USAGE procedure to pull report of tables which have the most free blocks.
I'm doing this so I could identify which tables that has the most free space so I could rebuild the table to reclaim back the free space. My current environment has a package which calls DBMS_SPACE.SPACE_USAGE procedure, this package will do a select loop for all tables & indexes belonging to a particular schema then feed it into space_usage procedure for it to do the analysis, once done the result will be inserted into a table as below.
Currently I'm using DBMS_SPACE.SPACE_USAGE procedure to pull report of tables which have the most free blocks.
I'm doing this so I could identify which tables that has the most free space so I could rebuild the table to reclaim back the free space. My current environment has a package which calls DBMS_SPACE.SPACE_USAGE procedure, this package will do a select loop for all tables & indexes belonging to a particular schema then feed it into space_usage procedure for it to do the analysis, once done the result will be inserted into a table as below.
0