日期:2014-05-16  浏览次数:20693 次

find 10 largest table in mysql
SELECT concat(round(table_rows/1000000,2),'M',' rows') as table_rows,concat(round(data_length/(1024*1024*1024),2),'G',' DATA') as data_size,concat(round(index_length/(1024*1024*1024),2),'G',' idx') as index_size,concat(round((data_length+index_length)/(1024*1024*1024),2),'G',' total_size') as total_size,concat(round(index_length/data_length,2),' idxratio') as index_ratio,concat(table_schema,'.',table_name) as table_name FROM information_schema.TABLES ORDER BY data_length+index_length DESC LIMIT 10;
?

?

?

?

?