Page 1 of 1

phpmyspace msql error

Posted: Fri Aug 03, 2007 2:49 am
by saghir
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/rayyan01/public_html/italkonphone/functions.php on line 44

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/rayyan01/public_html/italkonphone/functions.php on line 52

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/rayyan01/public_html/italkonphone/functions.php on line 78

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/rayyan01/public_html/italkonphone/functions.php on line 79


does anyone know why this happend please or any idea how i can fix this.

thankyou very much for your help

Posted: Fri Aug 03, 2007 7:39 am
by iknownothing
use the following to determine what your issue is:

Code: Select all

$sql = "SQL Statement here";

if (!mysql_query($sql)) {
die(mysql_error());
}

Re: phpmyspace msql error

Posted: Fri Aug 03, 2007 7:55 am
by superdezign
saghir wrote:Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/rayyan01/public_html/italkonphone/functions.php on line 44

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/rayyan01/public_html/italkonphone/functions.php on line 52

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/rayyan01/public_html/italkonphone/functions.php on line 78

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/rayyan01/public_html/italkonphone/functions.php on line 79
Errors without code are generally useless. It IS obvious, however, that you don't check your resources before using them. Always check all variables before using them.

is_resource may be useful, though if it's not a resource from a query, it'll likely just be NULL.