SELECT a.file_name, substr(A.tablespace_name,1,14) tablespace_name, trunc(decode(A.autoextensible,'YES',A.MAXSIZE-A.bytes+b.free,'NO',b.free)/1024/1024) free_mb, trunc(a.bytes/1024/1024) allocated_mb, trunc(A.MAXSIZE/1024/1024) capacity, a.autoextensible ae FROM ( SELECT file_id, file_name, tablespace_name, autoextensible, bytes, decode(autoextensible,'YES',maxbytes,bytes) maxsize FROM dba_data_files GROUP BY file_id, file_name, tablespace_name, autoextensible, bytes, decode(autoextensible,'YES',maxbytes,bytes) ) a, (SELECT file_id, tablespace_name, sum(bytes) free FROM dba_free_space GROUP BY file_id, tablespace_name ) b WHERE a.file_id=b.file_id(+) AND A.TABLESPACE_NAME=B.TABLESPACE_NAME(+) ORDER BY A.tablespace_name ASC;
Saturday, April 15, 2017
SQL query for finding all table spaces and their sizes in oracle database
Subscribe to:
Post Comments (Atom)
Perfect order of ODI export and import
Smart Export / Import is the recommended way to achieve such a migration. This is the easiest way to make sure all the dependencies are ta...
-
Getting the below error when installing oracle database 12c on linux machine Soft Limit: maximum stack size - This is a prerequisite con...
-
In general when we leave the database connection opened for a while in oracle sql developer, It will throw a "connection timeout"...
-
Please find the steps below to increase the performance of obiee 12c : 1. Tuning Hogging and Stuck Threads Hogging and stuck threads...
No comments:
Post a Comment