Select round (sum/ (1024x768*1024x7680) ts_size from where=Group by T.tablespace_name;
1. View the table space name and size
SelectA.tablespace_name, A.bytes/ 1024x768 / 1024x768"SumMB ", (A.bytes-B.bytes)/ 1024x768 / 1024x768"Used MB", B.bytes/ 1024x768 / 1024x768"Free MB",round(((A.bytes-B.bytes)/A.bytes)* -,2) "percent_used" from(SelectTablespace_name,sum(bytes) bytes fromDba_data_filesGroup byTablespace_name) A, (SelectTablespace_name,sum(bytes) Bytes,Max(bytes) Largest fromDba_free_spaceGroup bytablespace_name) bwhereA.tablespace_name=B.tablespace_nameOrder by((a.bytes-B.bytes)/A.bytes)desc;
2. View Table space usage
Select Tablespace_name, file_id , file_name , STATUS, online_status, round/ (1024x768 /1024x768) 0 ) total_space fromorder by tablespace_name;
3. View the table space physical file name and size
Select segment_name, tablespace_name, r.status, /1024x768) initialextent, /1024x768) nextextent, max_extents, v.curext curextent from Where = V.usn (+ ORDER by Segment _name;
4. View the rollback segment name and size
Select file_name from Dba_data_files
5. Query tablespace or data file Auto-expansion
Select df.tablespace_name name, DF. file_name " file ", f.phyrds pyr, f.phyblkrd PBR, f.phywrts pyw, f.phyblkwrt PBW From where F.file= df. file_id Order by Df.tablespace_name;
6. Monitoring the I/O ratio of table spaces
DBA Common SQL table space and data file