Jump to content

You have an error in your SQL syntax


devan

Recommended Posts

Hi, I am getting the following error in my UPDATE query : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'WHERE `productId`='1143'' at line 12

 

My code :

 

  $sqlEdit = "UPDATE CubeCart_inventory SET `productCode`='$prodcode',
										`quantity`='$prodqsa',
										`description`='$proddes', 
										`image`='$imagesaveme2',
										`price`='$prodsell',
										`name`='$prodtitle', 
										`cat_id`='$category',
										`sale_price`='$prodsale',
										`stock_level`='$prodqty', 
										`Prod_Condition`='$prodcon', 
										`Prod_Waiting`='$prodperiod',
									WHERE `productId`='$prodid'";
$result = @mysql_query($sqlEdit);

 

What might be the problem ? MySQL is saying line 12 is wrong : This Line : WHERE `productId`='$prodid'";

 

please help!  :confused:

Link to comment
https://forums.phpfreaks.com/topic/251529-you-have-an-error-in-your-sql-syntax/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.