Query:

SELECT ROUND(SUM(table_size) / 1024 / 1024, 2) AS 'Total Database Size (MB)' FROM (SELECT table_schema AS 'Database', SUM(data_length + index_length) AS 'table_size' FROM information_schema.TABLES GROUP BY table_schema ) as inner_query;

Result:

+--------------------------+
| Total Database Size (MB) |
+--------------------------+
| 411.72 |
+--------------------------+

Leave a Reply

Your email address will not be published. Required fields are marked *