title: Calling a stored procedure where one of the 'IN' variables is a list from Express API
body: <p>I have an Express API that gets options from my React app. There are multi-select boxes where they can have multiple options selected, in my case its baseball seasons. The options are 2018, 2017, 2016. So the user can select either none or all of them at one time. That gets sent to my Express app where I use a join on them to create a single string of the options. So if the user selects 2018 and 2016 the string '2018,2016' gets sent to my MySQL stored procedure. </p>
  
  <p>Here is my stored procedure:</p>
  
  <p><code>CREATE DEFINER='mysqlAdmin'@'%' PROCEDURE 'testproc'(in playerID int(6), in seasons varchar(100))
  BEGIN
      select ReleaseSpeed, EventID, LaunchAngle from Pitches where BatterID=playerID and YEAR(GameDate) in (seasons) and LaunchAngle is not null order by ReleaseSpeed desc limit 5;
  END</code></p>
  
  <p>Here is the call from my Express App:</p>
  
  <pre><code>const sql = "call testproc(?,?);";
    db.query(sql, [players[0],seasons], function(err, result, fields){
      if(err) throw err;
      console.log(result);
  });
  </code></pre>
  
  <p>The problem is when I call the stored procedure with the options it only gets results with pitches that have dates in the first year selected, in this case 2018. How can I get the string to act like two separate integers, so the <code>IN</code> part of the query works as intended?</p>