note 31553 deleted from function.mysql-num-rows by didou

From: Date: Thu, 19 Jun 2003 08:38:42 +0000
Subject: note 31553 deleted from function.mysql-num-rows by didou
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-50621@lists.php.net to get a copy of this message
Note Submitter: Janez Resnik, SI ---- $count_product_type_results = mysql_query( $sql_product_type_count ); Why is this line not returning the result from "SELECT COUNT(*) ..." query? My guess is that the correct line would be: $count_product_type_results = mysql_result(mysql_query( $sql_product_type_count ),0); You forgot to call mysql_fetch_array() or mysql_result() or any function that returns actual row or column and you are printing variable that is comonly named as $result which is of resource type. If you are experienced C++ programer, you could think of it as a "pointer" or "reference" to the whole resultset. You might want to try var_dump($count_product_type_results)...

« previous php.notes (#50621) next »