Problem: Connect Two Tables
List each student’s math grade, or show NULL if missing.
Sample data
The students table
ID | Name |
1 | Ali |
2 | Fatima |
3 | Omar |
The grades table
Student ID | Subject | Score |
1 | Math | 87.5 |
1 | History | 80.0 |
2 | Math | 91.0 |
Problem: Connect Two Tables
List each student’s math grade, or show NULL if missing.
Sample data
The students table
ID | Name |
1 | Ali |
2 | Fatima |
3 | Omar |
The grades table
Student ID | Subject | Score |
1 | Math | 87.5 |
1 | History | 80.0 |
2 | Math | 91.0 |