Is it possible to do an UPDATE SET @variable = something where the column name is a variable? I can't do a CREATE TABLE or ALTER TABLE for this particular problem.
SET @q = 'q'+ Quantity; @q becomes the column name q100
UPDATE table
SET @q = Price Update column q100 = Price
SET @q = 'q'+ Quantity; @q becomes the column name q100
UPDATE table
SET @q = Price Update column q100 = Price