We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ff4cda9 commit 99bb2e5Copy full SHA for 99bb2e5
SQL/SQL-50/Students_and_Examinations.sql
@@ -0,0 +1,7 @@
1
+select s.student_id, s.student_name, sub.subject_name, count(e.student_id) as attended_exams
2
+from Students s
3
+join Subjects sub
4
+left join Examinations e
5
+on sub.subject_name = e.subject_name and s.student_id = e.student_id
6
+group by s.student_id, s.student_name, sub.subject_name
7
+order by s.student_id asc;
0 commit comments