I am trying to count various bits of information on a game i am making, which is PHP & SQL based. I am having trouble with the following:
$esc1 = "SELECT * FROM `BETA_ESCROW` WHERE `reciever_id` = '$stat[id]' && `read` = '0'";
$esc2 = mysql_query($esc1);
$escrow = mysql_num_rows($esc2);
$classes = mysql_fetch_assoc(mysql_query("SELECT * FROM `BETA_CLASSES` WHERE `id` = '$stat[id]'"));
This is 2 different methods i have tried to count entries, but both come back with the same type of error:
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/content/d/e/f/defjam28/html/header.php on line 65
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/content/d/e/f/defjam28/html/header.php on line 70
IT is running on a Unix server if that helps any..
$esc1 = "SELECT * FROM `BETA_ESCROW` WHERE `reciever_id` = '$stat[id]' && `read` = '0'";
$esc2 = mysql_query($esc1);
$escrow = mysql_num_rows($esc2);
$classes = mysql_fetch_assoc(mysql_query("SELECT * FROM `BETA_CLASSES` WHERE `id` = '$stat[id]'"));
This is 2 different methods i have tried to count entries, but both come back with the same type of error:
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/content/d/e/f/defjam28/html/header.php on line 65
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/content/d/e/f/defjam28/html/header.php on line 70
IT is running on a Unix server if that helps any..