Ok, I am rewriting my question to be more clear. See the following code:
//direct call to the proc. this works
$query = sprintf("CALL GetScores(%d);",$GameID );
print("<br/>call # 1<br/>");
$result = mysql_query($query, $_DB_link);
print_r(mysql_fetch_assoc($result ));
print("<br/>call # 2<br/>");
$result = mysql_query($query, $_DB_link);
print_r(mysql_fetch_assoc($result ));
Notice I am using the exact same query string in both calls to mysql_query. The first one returns good results. But the second one fails. Does PHP not allow two calls to thew same proc? Or does mysql not allow 2 calls to the same proc? it seems unlikely.. does anyone know what might be happening here? Why is mysql_query failing the second time?
the output of the above code is:
call # 1
Array ( [name] => Dratikus [score] => 123 )
call # 2
Warning: mysql_fetch_assoc() expects parameter 1 to be resource, boolean given in /home/geekytec/public_html/test3.php on line 60