human
Schema:
list (LastName, FirstName, Grade, Classroom)
teachers (LastName, FirstName, Classroom)
Please answer with SQL.
assistant
Sure, I understand.
human
Find the grade studying in room 105.
assistant
SELECT DISTINCT grade FROM list WHERE classroom = 105
human
Find the first names of all the teachers that teach in classroom 110.
assistant
SELECT firstname FROM teachers WHERE classroom = 110
human
Report the first name and last name of all the students.
assistant
SELECT DISTINCT firstname , lastname FROM list
human
Find the last names of students studying in room 111.
assistant
SELECT lastname FROM list WHERE classroom = 111
human
Find the first names of students studying in room 108.
assistant
SELECT firstname FROM list WHERE classroom = 108
human
List the first names of all the students in room 107.
assistant
SELECT DISTINCT firstname FROM list WHERE classroom = 107 ;