Hi,
in versions less than 5.x, show table status gives informations about rows and
avg_row_length. The product gives you a correct approximation if the stats are
analyzed. This is for actions from the client.
another thing is the OS commands from your datadir (du -k).
Hope that helps.
Mathias
Selon Gordon Bruce [EMAIL PROTECTED]:
If you are on 5.0.n there is an INFORMATION_SCHEMA which you can query
like this. A casual scan of the mysql tables don't show any sizes and I
don't know of a way to get table/database size via SQL.
mysql select table_schema, sum(DATA_LENGTH) from
information_schema.tables group by 1;
++--+
| table_schema | sum(DATA_LENGTH) |
++--+
| information_schema | 0|
| mailprint | 2523448288 |
| mysql | 275126 |
| test | 16510|
++--+
4 rows in set, 79 warnings (6.22 sec)
-Original Message-
From: Salama hussein [mailto:[EMAIL PROTECTED]
Sent: Friday, June 10, 2005 1:31 PM
To: mysql@lists.mysql.com
Subject: How to control database size in MySQL Windows?
I think the answer to this is You can't. So I guess what I can do is
run a
query once every while and get the sizes of all the databases and if any
exceeds a predetermined size, revoke insert and update privilages.
What's is the SQL query like to get a database size and the SQL to get
the
names of all the databases?
Salama
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]