Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- SELECT
- tab.TABLE_SCHEMA as 'database',
- ROUND(sum(data_length) / 1024 / 1024, 2) as 'Tamanho em MB',
- ROUND(sum(index_length) / 1024 / 1024, 2) as 'Tamanho do indice em MB',
- ROUND(sum(DATA_LENGTH + INDEX_LENGTH) / 1024 / 1024, 2) as 'Tamanho toal em MB'
- FROM information_schema.TABLES as tab
- where TABLE_SCHEMA not in ('sys', 'information_schema')
- group by TABLE_SCHEMA
- order by sum(DATA_LENGTH + INDEX_LENGTH) desc;
Add Comment
Please, Sign In to add comment