in reply to Re: DBI: Better way to find number of rows in a table?
in thread DBI: Better way to find number of rows in a table?
Your method will work, but not the way you say.
In MySQL, COUNT(*) (without a WHERE clause) is optimized so that it will get the result from the description table, without physically counting the records.
Thus, your query will be slower than using COUNT. ;)
jeffa's method is the fastest you can get in this case.
|
|---|