-Original Message-
From: Elim Qiu [mailto:[EMAIL PROTECTED]
Sent: Friday, June 13, 2008 10:56 AM
To: mysql@lists.mysql.com
Subject: query counts of a database
I'm looking for a query that reports the count of each table in the
database.
the query should not assume the table list
If you are using MySQL 5.0 or later, use the INFORMATION_SCHEMA database.
It has an in-memory table of table names called (as you would expect) 'tables'.
SELECT table_rows,table_name FROM information_schema.tables
WHERE table_schema = 'whatever database you choose';
If you are using a current
PROTECTED]
To: Elim Qiu [EMAIL PROTECTED]; mysql@lists.mysql.com
Sent: Friday, June 13, 2008 10:02 AM
Subject: RE: query counts of a database
-Original Message-
From: Elim Qiu [mailto:[EMAIL PROTECTED]
Sent: Friday, June 13, 2008 10:56 AM
To: mysql@lists.mysql.com
Subject: query counts
Thanks a lot Edwards!
I'm using MySQL 5.1. Your query works great!
- Original Message -
From: Rolando Edwards [EMAIL PROTECTED]
To: Elim Qiu [EMAIL PROTECTED]; mysql@lists.mysql.com
Sent: Friday, June 13, 2008 10:32 AM
Subject: RE: query counts of a database
If you are using MySQL 5.0