A school stores student club membership data in a table called CLUB_MEMBER. MembershipID StudentName ClubName JoinDate YearGroup Active CM01 E. Owusu Chess ...

Assessment: Computer Science 0478 | Paper 2 Mock 01 | Algorithms, Programming and Logic Subject: Computer Science - 0478

Question 1 Report

A school stores student club membership data in a table called CLUB_MEMBER.

MembershipIDStudentNameClubNameJoinDateYearGroupActive
CM01E. OwusuChess Club2023-09-0510TRUE
CM02F. NakamuraDrama Society2023-09-1011TRUE
CM03G. Da SilvaChess Club2023-09-0510FALSE
CM04H. KhanCoding Club2023-10-019TRUE
CM05E. OwusuCoding Club2023-10-1510TRUE
CM06J. LarsenDrama Society2023-09-1211TRUE
CM07F. NakamuraChess Club2024-01-1011TRUE

(a) Write an SQL query to find all clubs that student 'E. Owusu' has joined. [2]

Answer Details

(a) Finding all clubs that E. Owusu has joined: [2]

SELECT ClubName
FROM CLUB_MEMBER
WHERE StudentName = 'E. Owusu'

[1] for SELECT ClubName, [1] for WHERE StudentName = 'E. Owusu'.

Expected result:

ClubName
Chess Club
Coding Club

E. Owusu appears in two records: CM01 (Chess Club) and CM05 (Coding Club). The query selects only the ClubName column rather than all columns, which is appropriate because the question asks specifically about clubs, not full membership details. Using SELECT * would also be accepted but would return extra information not asked for.

Download The App On Google Playstore

Everything you need to excel in your exams

Green Bridge CBT Mobile App
Personalized AI Learning Chat Assistant
200,000+ Exam Questions Across IGCSE, JAMB, WAEC & NECO
Over 3,900 Lesson Notes
Offline Support - Learn Anytime, Anywhere
Green Bridge Timetable
Literature Summaries & Potential Questions
Track Your Performance & Progress
In-depth Explanations for Comprehensive Learning