title: Query to fetch 1 row in table, and many rows from another table, referenced in that row
body: <p>So I have 2 tables in my database, they are 'workouts' and 'exercises'. Workouts contains a row called exercises which is a comma-separated list of exercise IDs - from the 'exercises' table e.g. '1,2,3'.</p>
  
  <p>My question is, can I write a single query to allow me to select a row from the workouts table, say one with an id of 1, and have MySQL fetch each of the exercises from the list in that row, returning them within the 'workout' row?</p>
  
  <p>At the moment I'm using PHP to select the workout row, and then making individual requests for each of the exercises, resulting in serious inefficiency.</p>
  
  <p>I took a look at <a href="https://stackoverflow.com/questions/4232274/joining-rows-as-array-from-another-table-for-each-row">Joining rows as array from another table for each row</a> and also did some research into the group_concat() function, but I'm not sure that's what I'm after.</p>
  
  <p><strong>Update</strong>
  Here are the 2 tables:
  <img src="https://i.stack.imgur.com/lJPBq.jpg" alt="enter image description here"></p>