Basic SQL question
Date: 09/09/07
(MySQL Communtiy) Keywords: sql
The question from the beginner. Let's assume I have a table of students and classes they take. I know, how to retrieve number of classes for each student.
SELECT student COUNT(class) FROM tbl GROUP BY student;
I need to select all student who take 3 or more classes. What is the SQL syntaxis to say WHERE COUNT > 3?
Thank you.
Source: http://community.livejournal.com/mysql/118761.html