SQL > select a.file_id "FileNo",a.tablespace_name "Tablespace_name", 2 a.bytes "Bytes",a.bytes-sum(nvl(b.bytes,0)) "Used", 3 sum(nvl(b.bytes,0)) "Free", 4 sum(nvl(b.bytes,0))/a.bytes*100 "%free" 5 from dba_data_files a, dba_free_space b 6 where a.file_id=b.file_id(+) 7 group by a.tablespace_name , 8 a.file_id,a.bytes order by a.tablespace_name;