Professional Documents
Culture Documents
SQL Exercises 8: Instruction
SQL Exercises 8: Instruction
SQL EXERCISES 8
INSTRUCTION
Use one of the following in each task below: EXCEPT, INTERSECT, or UNION.
1. List teachers' and students' surnames. Show the result as a single list.
2. List such cities where there is a campus and at least one student is living in the city.
3. List such cities where there is a campus and no student is living in the city.
4. List such years when at least one teacher was born OR at least one student was born. Display the
result in descending order.
5. List such years when at least one teacher was born AND at least one student was born
6. List such years when at least one teacher was born AND no student was born.
7. List such years when at least one student was born AND no teacher was born. Display the result in
descending order.