Re: MySQL/PHP Update
| From: | Jason Wong | Date: | Thu, 28 Mar 2002 15:05:12 +0000 |
| Subject: | Re: MySQL/PHP Update | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-18000@lists.php.net to get a copy of this message | ||
On Thursday 28 March 2002 17:04, cristi radulescu wrote:
> i think the problem is bad syntax:
> you should try:
>
> mysql_query("update prod_list set prod_manu=$prod_man where
> sku='".$prod."'");
>
> that is because when you have single quotes you will not evaluate the
> expression so your querry will do the update only for sku equally with
> the string '$prod'...
I'm afraid that is incorrect.
Try it for yourself:
<?
$doo = 'dah';
echo "Doo is '$doo'";
?>
His problem lies elsewhere.
--
Jason Wong -> Gremlins Associates -> www.gremlins.com.hk
/*
Nature abhors a virgin -- a frozen asset.
-- Clare Booth Luce
*/