JerryGolem
Programmer
I am new to mysql and have created a script that is trying to access a database that I have created on my ISP. I have no idea what the following message means. Please help. I got the example from "Create Dynamic Web Pages Using PHP and Mysql" by David Tansley.
Message:
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/jgolem/public_html/insertcust.php on line 48
Code:
$sql = 'SELECT `CustomerEmail` FROM `CustomerInformation` WHERE 1 AND `CustomerEmail` = \'jgolem@hotmail.com\' LIMIT 0, 30';
# Line 41
$result=mysql_query($sql,$connection);
$num_rows=mysql_num_rows($result);
Message:
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/jgolem/public_html/insertcust.php on line 48
Code:
$sql = 'SELECT `CustomerEmail` FROM `CustomerInformation` WHERE 1 AND `CustomerEmail` = \'jgolem@hotmail.com\' LIMIT 0, 30';
# Line 41
$result=mysql_query($sql,$connection);
$num_rows=mysql_num_rows($result);