title: How do I use properly CASE..WHEN in MySQL
body: <p>Here is a demo query, notice it is very simple, Fetches only where base_price is 0,
  And still, it chooses the condition 3:</p>
  
  <pre><code>SELECT
     CASE course_enrollment_settings.base_price
      WHEN course_enrollment_settings.base_price = 0      THEN 1
      WHEN course_enrollment_settings.base_price&lt;101      THEN 2
      WHEN course_enrollment_settings.base_price&gt;100 AND   
                        course_enrollment_settings.base_price&lt;201 THEN 3
          ELSE 6
     END AS 'calc_base_price',
     course_enrollment_settings.base_price
  FROM
      course_enrollment_settings
  WHERE course_enrollment_settings.base_price = 0
  </code></pre>
  
  <p><code>base_price</code> is <code>decimal(8,0)</code></p>
  
  <p>When run this on my DB, I get:</p>
  
  <blockquote>
    <p>3 0<br>
    3 0<br>
    3 0<br>
    3 0<br>
    3 0</p>
  </blockquote>