Question title says it all. I'm using PHP5 and MySQL.
EDIT:
I'm using mysql_...() functions.
Question title says it all. I'm using PHP5 and MySQL.
EDIT:
I'm using mysql_...() functions.
if (mysql_num_rows($query_identifier) == 0)
echo "Query returned 0 rows";
Additionally, mysql_query() returns false
in case of an error.
If you are using mysqli_ functions, you can call $stmt->num_rows(). But only after calling $stmt->store_result() to ensure all the rows have been returned.