I am trying to update a row and get its contents at the same time. I am using the following query:
UPDATE users SET number=number+1 OUTPUT DELETED.* WHERE ID=?
I could do this in 2 queries, but I want to keep things atomic to avoid a race condition.