At 12:39 -0800 11/1/05, Kevin Burton wrote:
MyISAM has a cool feature where it keeps track of the internal row count so that

SELECT COUNT(*) FROM FOO executes in constant time.  Usually 1ms or so.

The same query on INNODB is O(logN) since it uses the btree to satisfy the query.

I believe that MyISAM just increments an internal count so that every insert/delete changes the count.

Are there plans to add this to INNODB? I was relying on this for my database monitoring app and noticed that it was killing my performance (I forgot about this problem...)

What would the row count mean when you can have multiple transactions
operating on the table at the same time, inserting and deleting into
different parts of the table?

--
Paul DuBois, MySQL Documentation Team
Madison, Wisconsin, USA
MySQL AB, www.mysql.com

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to