I need to write a php script that includes a part where the database is queried to find out if there are any records matching a given SELECT query...
It just needs to find out if there are records that match or not, but outputting the number of such records would be quite acceptable, because I could write the rest of the code accordingly.
Supposing that the way to do this is like this:
$result=mysql_query("are there any records in 'table' WHERE ...)
Would I still use $row=mysql_fetch_array($result) to get the answer, and if so, I should access the array by using $row['What?']
It just needs to find out if there are records that match or not, but outputting the number of such records would be quite acceptable, because I could write the rest of the code accordingly.
Supposing that the way to do this is like this:
$result=mysql_query("are there any records in 'table' WHERE ...)
Would I still use $row=mysql_fetch_array($result) to get the answer, and if so, I should access the array by using $row['What?']
