Get size of database in bytes and rows
Published by Nicholas Dunbar on February 9th, 2014
How to get the size of the database in MySQL?
Replace database_name with the database name from which you want the size in bytes and rows:
SELECT t.table_schema,SUM(t.table_rows) AS row_count,SUM(t.data_length) AS data_volume
FROM information_schema.tables t
WHERE table_schema ='database_name'
GROUP BY t.table_schema
FROM information_schema.tables t
WHERE table_schema ='database_name'
GROUP BY t.table_schema