1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
|
select nvl(b.tablespace_name,
nvl(a.tablespace_name,'UNKNOWN')) "Tablespace",
kbytes_alloc "Taille",
decode(Allouable, 0, kbytes_alloc, allouable) "Extend",
kbytes_alloc-nvl(kbytes_free,0) "Uti réel",
nvl(kbytes_free,0) "Lib réel",
trunc((kbytes_alloc-nvl(kbytes_free,0))/kbytes_alloc, 4)*100 "Uti réel %",
decode(Allouable, 0, kbytes_alloc, allouable)-(kbytes_alloc-nvl(kbytes_free,0)) "Lib virt",
trunc((kbytes_alloc-nvl(kbytes_free,0))/decode(Allouable, 0, kbytes_alloc, allouable), 4)*100 "Uti virt %",
data_files "Fichiers "
from ( select sum(bytes)/1024/1024 Kbytes_free,
max(bytes)/1024/1024 largest,
tablespace_name
from sys.dba_free_space
group by tablespace_name ) a,
( select sum(bytes)/1024/1024 Kbytes_alloc,
sum(maxbytes)/1024/1024 Allouable,
tablespace_name,
count(*) data_files
from sys.dba_data_files
group by tablespace_name )b
where a.tablespace_name (+) = b.tablespace_name
order by 1; |
Partager