title: Does MySQL queue queries?
body: <p>What happens if there are two people sending the same query at the same time to the database and one makes the other query return something different? </p>
  
  <p>I have a shop where there is one item left. Two or more people buy the item and the query arrives at the exact same time on the MySQL server. My guess is that it will just queue but if so, how does MySQL pick the first one to execute and can i have influence on this?</p>