I want to subtract a number directly from the database. Instead of Retrieving it, Subtracting it then Updating the DB. Is there any way I can do this?
UPDATE Product
SET stock='$qty'
where productId = '$productId' and size='$size' and color='$color'
The stock should be ('numberInDB' - $qty ), is there any way i can do this directly?