Saturday, October 14, 2017

Few scripts for Your Oracle Database …..

 SQL> select sum(bytes)/1024/1024/1024 “SIZE_GB_TOTAL” from dba_data_files;

SIZE_GB_TOTAL

2671.33588

SQL> select sum(bytes)/1024/1024/1024 “SIZE_GB_ACTUAL” from dba_segments;

2084.94

SQL> select sum(bytes)/1024/1024/1024 “SIZE_GB_FREE” from dba_free_space;

SIZE_GB_FREE

585.972672


Note :-

dba_free_space:- describes the free extents in all tablespaces in the database.

dba_segments :- describes the storage allocated for all segments in the database.

dba_data_files :- describes d