title: How to check for multiple values in MySQL using IN and a parameter?
body: <p>I'm generating a string of values (colors) like so:</p>
  
  <pre><code>  'red|green|blue|yellow|orange|black'
  </code></pre>
  
  <p>Can I pass this as a parameter (param_cols) to a MySQL stored procedure and check against it like so:</p>
  
  <pre><code>  SELECT tbl.products
    FROM table AS tbl
    WHERE tbl.color IN ( param_cols );
  </code></pre>
  
  <p><strong>Question</strong>:
  Is this possible using a parameter? Should I use IN, LIKE or REGEX?</p>
  
  <p><strong>EDIT</strong>:<br>
  THANKS for the hints. However I'm more concerned about whether I can pass my list of colors as a variable into the stored procedure vs having to insert each color individually?</p>