I run a query. If no records are returned I don't want to buildmy html table. How do I determine the # of records returned from the query. ..Or is there another way :-)
http://www.php.net/mysql_num_rows
what if I'm using an odbc connector? $num_rows = odbc_num_rows($cur); always seems to return -1???
That would be an error (which is why I always test for $rows <=0) Is $sur your result set?
$cur is my result set and do display records succesfully. Why the -1?
RTFM
Note: Using odbc_num_rows() to determine the number of rows available after a SELECT will return -1 with many drivers.