Sander,
>I'm thinking of switching to InnoDB, however - my application does a few
>COUNT(*) .... WHERE .... queries on large tables (somewhere between 50K
>and 2M rows)
>
>I've read up on InnoDB and its issues with COUNT(*) on entire tables,
>but is there a reason to assume that InnoDB is also slower when there is a
WHERE
>clause present?
no, in the case of COUNT(*) of an entire table MyISAM
is very fast because it keeps a table row count internally.
In the case of COUNT(*) ... WHERE ...
both MyISAM and InnoDB have to really count the matching
rows. Then the speed depends mainly on the amount of disk
i/o needed to access the rows.
Actually, the reason I did not originally put a row count to
InnoDB tables was that I thought most real applications
would ask queries like COUNT(*) ... WHERE. Only later
I have learnt that a plain COUNT(*) is quite common :).
>Regards,
>
>Sander
Regards,
Heikki
http://www.innodb.com
---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php