mysql update table sum based on value same table code example Example: mysql update sum same table UPDATE products SET quantity = quantity + 10 WHERE id = 8