Re[2]: [PHP-DB] problem....

From: Date: Wed, 23 Jun 2004 13:25:33 +0000
Subject: Re[2]: [PHP-DB] problem....
References: 1 2 3 4 5  Groups: php.db 
Request: Send a blank email to php-db+get-34892@lists.php.net to get a copy of this message
Hello water_foul, what about this? If you do for the first time: $pic=mysql_fetch_array($pic) it will work, but the SECOND TIME that you do: $pic=mysql_fetch_array($pic).... it will fail, and thats because $pic is no longer a resource identificator... and you will get: > > Warning: mysql_fetch_array(): supplied argument is not a valid MySQL > > result > try this: $pic=mysql_query("Select Rune, username FROM runeRunner where (User_ID=3)0,$connection); $xx=mysql_fetch_array($pic); do you follow me?... > >> > why doesn't this work: > >> > $pic=mysql_query('SELECT Rune, username FROM RuneRunner > >> > RuneRunner_1 WHERE (User_ID = 3)',$connection); > >> > $pic=mysql_fetch_array($pic); P.S. if you need to trace, you can do var_dump($pic); -- Best regards, Pablo

« previous php.db (#34892) next »