update multiple columns in mysql php code example
Example 1: php update multiple columns
$sql = "UPDATE product_list SET product_name='".$product_name."',product_category='".$product_category."',product_price='".$product_price."',product_description='".$product_description."',size_category='".$size_category."'";
Example 2: mysql updating multiple column values from array variable
"UPDATE product_list
set
product_name='$product_name',
product_category ='$product_category',
product_price='$product_price',
product_description='$product_description',
product_size_category='$size_category'
where product_id='$product_id'
"
Example 3: update multiple columns in mysql
UPDATE newpurchase
SET receive_qty = 20, pub_lang = 'Hindi', receive_dt = '2008-07-10'
WHERE purch_price > 50;