I'm trying to Select and list only the Courses where more than 2 students are registered, I'm executing the following query but its giving me errors, please help
SELECT DISTINCT COURSES FROM STUDENTTBL WHEN COUNT(COURSES)>2;
Courses Students
Maths Dave
Maths John
Maths Nancy
Maths Ron
History Dave
History John
History Nancy
Science Dave
Science john
the expected output is
Maths
History