Tuesday, February 3, 2015

Query to find size of MySQL DB

When we are using shared hosting server with Windows or Linux, without any control panel software, It's little bit hard to find user's disk usage on mysql.

In this case we can use  following command on mysql to get size of database.

SELECT table_schema "DB Name", Round(Sum(data_length + index_length) / 1024 / 1024, 1) "DB Size in MB" FROM information_schema.tables GROUP  BY table_schema;

No comments:

Connect MS-SQL Database on PHP under Ubuntu-18.04

I can see that several tutorials available over Internet for "Connecting Ms SQL by PHP code on Ubuntu 18.04", But as much as I sa...