I have some question ... example: a user will buy something for his USD
This is how I used to do it many years ago..
results = query("UPDATE table SET value=value-5 WHERE value>=5 AND ID=1") if (results == 1) YEY!
(Is this still a reliable method?)