Question: The finals table has columns hall (strings) and course (strings), and has rows for each lecture hall in which a course is holding its
The finals table has columns hall (strings) and course (strings), and has rows for each lecture hall in which a course is holding its final exam. Each course and each hall value may appear multiple times because a course may use multiple lecture halls at the same time, and a lecture hall may hold finals for multiple courses at different times. The sizes table has columns room (strings) and seats (numbers), and has one row per unique room on campus containing the number of seats in that room. Each room appears once. All lecture halls are rooms. Create a table with two columns, course (string) and seats (number), and with one row containing the name of the course and the total number of seats in final rooms for that course. Only include a row for each course that uses at least two rooms for its final. finals: hall RSF course 61A Wheeler 61A RSF 61B sizes: room seats RSF 900 Wheeler 700 310 Soda 40 SELECT course, SUM(___________) AS seats FROM (a) (b) result: course 61A GROUP BY seats 1600 ----- (c)
Step by Step Solution
There are 3 Steps involved in it
To fill in the placeholders a b and c in the SQL query given the tables finals and sizes we want to ... View full answer
Get step-by-step solutions from verified subject matter experts
