How to know Data Size through Scripts

Dear all,

I am research on several commands through which I can monitor the size
of specific data of tables in different . I want to write a script that
fetches the data of different database tables & databases too daily and
write it into a file .

Is there is any way or commands to achieve this.

I researched a lot , I find commands as :

SELECT
CONCAT(sum(ROUND(((DATA_LENGTH + INDEX_LENGTH - DATA_FREE) / 1024 /
1024),2))," MB") AS Size FROM INFORMATION_SCHEMA.TABLES where
TABLE_SCHEMA like 'abc' ;

Is there is any simple commands to know this.


Thanks & best Regards,

Adarsh Sharma



--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql?unsub=gcdmg-mysql-2 [at] m.gmane.org
Adarsh Sharma [ Mo, 14 März 2011 08:11 ] [ ID #2056524 ]
Datenbanken » gmane.comp.db.mysql.general » How to know Data Size through Scripts

Vorheriges Thema: Table Records Deleted by anonymous user!
Nächstes Thema: [ERROR] /usr/sbin/mysqld: Can't find file: './mysql/user.frm'