title: Select columns other than the one specified in GROUP BY clause
body: <p>Is there a way to select columns other the one specified in the group by clause?
  Let's say I have the following schema:</p>
  
  <p>Student(id, name, age), Course(id, name, credit), Enrollment(student_id, course_id, grade)</p>
  
  <p>I want to query for each course the following: course's name, student_count.</p>
  
  <p>I came up with workaround, but I was wondering if there's a cleaner way to do this:</p>
  
  <pre><code>SELECT MAX(c.name), COUNT(distinct e.student_id)
  FROM Enrollment e
  INNER JOIN Course c ON c.id = e.course_id
  GROUP BY e.course_id;
  </code></pre>