title: not a GROUP BY expression
body: <p>I am creating the following sql query:</p>
  
  <pre><code>SELECT B.AFLEVERING_ID,A.NAAM, COUNT(B.AFLEVERING_ID) AS aantal_keer_bekeken
  FROM BEKEKENVIA B, AFLEVERING A
  WHERE A.AFLEVERING_ID = B.AFLEVERING_ID
  GROUP BY B.AFLEVERING_ID
  ORDER BY B.AFLEVERING_ID ASC;
  </code></pre>
  
  <p>Why gives it the error:</p>
  
  <pre><code>ORA-00979: not a GROUP BY expression
  00979. 00000 -  "not a GROUP BY expression"
  *Cause:    
  *Action:
  Error at Line: 42 Column: 24
  </code></pre>
  
  <p>Why is this and how can I solve this? It is Oracle SQL.</p>