np takim zapytaniem:
SELECT NVL(b.tablespace_name,
NVL(a.tablespace_name,'UNKOWN')) name,
round(kbytes_alloc/1024,2) "allocated (MB)",
round((kbytes_alloc-NVL(kbytes_free,0))/1024,2) "used (MB)",
round(NVL(kbytes_free,0)/1024,2) "free (MB)",
round(((kbytes_alloc-NVL(kbytes_free,0))/kbytes_alloc)*100,2) pct_used
FROM ( SELECT SUM(bytes)/1024 Kbytes_free,
tablespace_name
FROM sys.dba_free_space
GROUP BY tablespace_name ) a,
( SELECT SUM(bytes)/1024 Kbytes_alloc,
SUM(maxbytes)/1024 kbytes_max,
tablespace_name
FROM sys.dba_data_files
GROUP BY tablespace_name )b
WHERE a.tablespace_name (+) = b.tablespace_name
ORDER BY "allocated (MB)" desc;