title: Case statement syntax MySQL
body: <p>I have a MySQL stored procedure that is working perfectly</p>
  
  <pre><code>BEGIN 
  SELECT ID, SID, SerialNumber, SerialType
  FROM orders
  WHERE paymentStatus =  'Completed'
  AND paymentSuccess =  '1'
  AND VerificationStatus IS NULL 
  OR VerificationStatus NOT IN ('Found', 'NotFound', 'NotVerified');
  END
  </code></pre>
  
  <p>however I need to change it to return differently based upon the value that is passed into SerialType. I think a case statement might be the best way to do this, but struggling to find the correct syntax, and example below displays the logic and what I've tried thus far.</p>
  
  <pre><code>BEGIN 
  SELECT ID, SID, SerialNumber, SerialType
  FROM orders
  CASE
      WHEN SerialType IN ('Var1','Var2') THEN
          WHERE paymentStatus =  'Completed' AND paymentSuccess =  '1';
      WHEN SerialType IN ('Var3','Var4') THEN
          WHERE paymentStatus =  'Completed' AND paymentSuccess =  '1' AND VerificationStatus IS NULL OR VerificationStatus NOT IN ('Found', 'NotFound', 'NotVerified');
  END CASE
  END
  </code></pre>