Forum Moderators: coopster
This will work but is there an easier way? maybe one with only one SQL statment?
eelixduppy's solution should be ok. Are you sure your variable is populating ok?
Try just running:
$query = "update table_name set quantity = (quantity+1)";
If you don`t want all rows to be updated, you may need a where clause.
$query = "update table_name set quantity = (quantity+".$add_value.") WHERE id = '1'";
etc
dc