|
Posted by Captain Paralytic on 07/26/07 14:03
On 26 Jul, 14:20, Rik <luiheidsgoe...@hotmail.com> wrote:
| mysql_num_rows(), underneath the surface it is essentially the same
as
| FOUND_ROWS(), with the added bonus of getting an integer straight
back.
I don't think so Rik!
mysql_num_rows() will tell you how many rows have been returned in
this particular request.
FOUND_ROWS() will tell you how many rows would have been returned if
you did not have a LIMIT clause on the previous query and it also
requires the previous query to have had SQL_CALC_FOUND_ROWS in it.
SELECT FOUND_ROWS() AS num FROM TABLE
will return you the value of 0 for as many rows as there are in the
table.
Navigation:
[Reply to this message]
|