Oracle查看表實際占用空間和實際行數


select t.table_name,t.num_rows from user_tables t ORDER BY NUM_ROWS DESC;//實際行數

 

analyze table emp compute statistics;
select num_rows * avg_row_len
from user_tables
where table_name = 'TB_SYS_LOG';//某一個表占用的空間

 

analyze table emp compute statistics;
select table_name,num_rows * avg_row_len len
from user_tables order by len desc;//所有表占用的空間


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM