GET THE DATABASE SIZE FROM THE MYSQL QUERY BROWSER



Run the below query you can get the Data Base Size in MySQL. 

If you run the query which is given below in MySQL Query Browser then you will get the two columns first will display the Data Base Name and the second will display the Data Base Size in MB. 




This will display list of all database :

1
2
SELECT table_schema "Data Base Name", sum( data_length + index_length ) / 1024 / 1024 "Data Base Size in MB" 
FROM information_schema.TABLES GROUP BY table_schema ; 



This will display specific database db_name:

1
2
SELECT table_schema "Data Base Name", sum( data_length + index_length ) / 1024 / 1024 "Data Base Size in MB" 
FROM information_schema.TABLES WHERE table_schema = "db_name"

Comments