title: Oracle SQL - GROUP BY not working
body: <p>When I am run the below query, I get the following result. </p>
  
  <p>I don't understand why I am not getting the expected result from the GROUP BY.</p>
  
  <p>How can I fix this so I get the expected result?</p>
  
  <pre><code>SELECT
    status AS "ROW LABELS",
    (case when order = 'INTERNET' THEN COUNT(*) end) AS "INTERNET"
  FROM
      order
      ,status
  WHERE  order       =   status
  GROUP BY status, order_source
  order by 1;
  </code></pre>
  
  <p>Data is here
  <a href="https://drive.google.com/file/d/0BzWMxMDCgXFaSk5TTWV2SEEzTFU/edit?usp=sharing" rel="nofollow noreferrer">https://drive.google.com/file/d/0BzWMxMDCgXFaSk5TTWV2SEEzTFU/edit?usp=sharing</a>
  I couldn't format the data here well.</p>
  
  <p>Following Dnoeth's answer, I am getting the below result:
  <img src="https://i.stack.imgur.com/tnMKa.png" alt="enter image description here">
  See, I need the row labels to be grouped up, but they're not being grouped. Putting count outside the case helped a little. 
  I have edited the query to get the idea across, the query is more complicated than what I am presenting here</p>