mysql -u root -pmysql;
SELECT TABLE_NAME AS "Table Name", table_rows AS "Quant of Rows", ROUND((data_length + index_length)/1024/1024,2) AS "Total Size Mb" FROM information_schema.TABLES WHERE information_schema.TABLES.table_schema='database_name';
I want to create a shell script which will execute these command and return the result.
How may i run this commands through shell script ?