RE: [PHP-DB] Problem with php and mysql From: Boaz Yahav (berber <email protected>)
Date: 09/30/00

What is $Toto? what does the MySQL log show?
Try doing :

$rtest = mysql_db_query("test",$test) or die(mysql_error());

Sincerely

     berber

Visit http://www.weberdev.com Today!!!
To see where PHP might take you tomorrow.

> -----Original Message-----
> From: Emmanuel Halphen [mailto:manu <email protected>]
> Sent: Saturday, September 30, 2000 8:21 PM
> To: php-db <email protected>
> Subject: [PHP-DB] Problem with php and mysql
>
>
> Hi,
>
>
> I have a little problem with php and MySQL.
>
> This is an extract of the code of my page :
>
> $test = "SELECT * FROM Test WHERE $Toto <> 1";
> $rtest = mysql_db_query("test",$test)
> while($etest = mysql_fetch_array($rtest)) {
> echo $etest["Numero"];
> }
>
> While I execute this page, I have the following error :
>
> Warning: Supplied argument is not a valid MySQL result resource
>
> When I put in the code : echo $rtest; , I have the following
> response :
> Resource id #2
>
> Does somebody has an answer or an explication ?
>
>
> Thanks a lot.
>
>
> Emmanuel
>
>
> --
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-db-unsubscribe <email protected>
> For additional commands, e-mail: php-db-help <email protected>
> To contact the list administrators, e-mail:
> php-list-admin <email protected>
>

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-db-unsubscribe <email protected>
For additional commands, e-mail: php-db-help <email protected>
To contact the list administrators, e-mail: php-list-admin <email protected>