query_id
int64
0
7k
database_id
stringclasses
140 values
table_id
sequencelengths
1
5
query
stringlengths
16
224
answer
stringlengths
18
577
difficulty
stringclasses
4 values
2,500
movie_1
[ "Movie", "Rating" ]
What are the names and years of the movies that has the top 3 highest rating star?
SELECT T2.title , T2.year FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID ORDER BY T1.stars DESC LIMIT 3
hard
2,501
movie_1
[ "Movie", "Rating" ]
What are the names and years released for the movies with the top 3 highest ratings?
SELECT T2.title , T2.year FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID ORDER BY T1.stars DESC LIMIT 3
hard
2,502
movie_1
[ "Movie", "Rating" ]
For each director, return the director's name together with the title of the movie they directed that received the highest rating among all of their movies, and the value of that rating. Ignore movies whose director is NULL.
SELECT T2.title , T1.stars , T2.director , max(T1.stars) FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID WHERE director != "null" GROUP BY director
hard
2,503
movie_1
[ "Movie", "Rating" ]
For each director, what are the titles and ratings for all the movies they reviewed?
SELECT T2.title , T1.stars , T2.director , max(T1.stars) FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID WHERE director != "null" GROUP BY director
hard
2,504
movie_1
[ "Movie", "Rating" ]
Find the title and star rating of the movie that got the least rating star for each reviewer.
SELECT T2.title , T1.rID , T1.stars , min(T1.stars) FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID GROUP BY T1.rID
medium
2,505
movie_1
[ "Movie", "Rating" ]
For each reviewer id, what is the title and rating for the movie with the smallest rating?
SELECT T2.title , T1.rID , T1.stars , min(T1.stars) FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID GROUP BY T1.rID
medium
2,506
movie_1
[ "Movie", "Rating" ]
Find the title and score of the movie with the lowest rating among all movies directed by each director.
SELECT T2.title , T1.stars , T2.director , min(T1.stars) FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID GROUP BY T2.director
medium
2,507
movie_1
[ "Movie", "Rating" ]
For each director, what is the title and score of their most poorly rated movie?
SELECT T2.title , T1.stars , T2.director , min(T1.stars) FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID GROUP BY T2.director
medium
2,508
movie_1
[ "Movie", "Rating" ]
What is the name of the movie that is rated by most of times?
SELECT T2.title , T1.mID FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID GROUP BY T1.mID ORDER BY count(*) DESC LIMIT 1
extra
2,509
movie_1
[ "Movie", "Rating" ]
What is the name of the movie that has been reviewed the most?
SELECT T2.title , T1.mID FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID GROUP BY T1.mID ORDER BY count(*) DESC LIMIT 1
extra
2,510
movie_1
[ "Movie", "Rating" ]
What are the titles of all movies that have rating star is between 3 and 5?
SELECT T2.title FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID WHERE T1.stars BETWEEN 3 AND 5
medium
2,511
movie_1
[ "Movie", "Rating" ]
What are the titles of all movies that have between 3 and 5 stars?
SELECT T2.title FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID WHERE T1.stars BETWEEN 3 AND 5
medium
2,512
movie_1
[ "Reviewer", "Rating" ]
Find the names of reviewers who had given higher than 3 star ratings.
SELECT T2.name FROM Rating AS T1 JOIN Reviewer AS T2 ON T1.rID = T2.rID WHERE T1.stars > 3
medium
2,513
movie_1
[ "Reviewer", "Rating" ]
What are the names of the reviewers who have rated a movie more than 3 stars before?
SELECT T2.name FROM Rating AS T1 JOIN Reviewer AS T2 ON T1.rID = T2.rID WHERE T1.stars > 3
medium
2,514
movie_1
[ "Reviewer", "Rating" ]
Find the average rating star for each movie that are not reviewed by Brittany Harris.
SELECT mID , avg(stars) FROM Rating WHERE mID NOT IN (SELECT T1.mID FROM Rating AS T1 JOIN Reviewer AS T2 ON T1.rID = T2.rID WHERE T2.name = "Brittany Harris") GROUP BY mID
extra
2,515
movie_1
[ "Reviewer", "Rating" ]
What is the average rating for each movie that has never been reviewed by Brittany Harris?
SELECT mID , avg(stars) FROM Rating WHERE mID NOT IN (SELECT T1.mID FROM Rating AS T1 JOIN Reviewer AS T2 ON T1.rID = T2.rID WHERE T2.name = "Brittany Harris") GROUP BY mID
extra
2,516
movie_1
[ "Reviewer", "Rating" ]
What are the ids of the movies that are not reviewed by Brittany Harris.
SELECT mID FROM Rating EXCEPT SELECT T1.mID FROM Rating AS T1 JOIN Reviewer AS T2 ON T1.rID = T2.rID WHERE T2.name = "Brittany Harris"
hard
2,517
movie_1
[ "Reviewer", "Rating" ]
What are the ids of all moviest hat have not been reviewed by Britanny Harris?
SELECT mID FROM Rating EXCEPT SELECT T1.mID FROM Rating AS T1 JOIN Reviewer AS T2 ON T1.rID = T2.rID WHERE T2.name = "Brittany Harris"
hard
2,518
movie_1
[ "Rating" ]
Find the average rating star for each movie that received at least 2 ratings.
SELECT mID , avg(stars) FROM Rating GROUP BY mID HAVING count(*) >= 2
medium
2,519
movie_1
[ "Rating" ]
For each movie that received more than 3 reviews, what is the average rating?
SELECT mID , avg(stars) FROM Rating GROUP BY mID HAVING count(*) >= 2
medium
2,520
movie_1
[ "Rating" ]
find the ids of reviewers who did not give 4 star.
SELECT rID FROM Rating EXCEPT SELECT rID FROM Rating WHERE stars = 4
hard
2,521
movie_1
[ "Rating" ]
What are the ids of all reviewers who did not give 4 stars?
SELECT rID FROM Rating EXCEPT SELECT rID FROM Rating WHERE stars = 4
hard
2,522
movie_1
[ "Rating" ]
Find the ids of reviewers who didn't only give 4 star.
SELECT rID FROM Rating WHERE stars != 4
easy
2,523
movie_1
[ "Rating" ]
What are the ids of all reviewers who have not given 4 stars at least once?
SELECT rID FROM Rating WHERE stars != 4
easy
2,524
movie_1
[ "Movie", "Reviewer", "Rating" ]
What are names of the movies that are either made after 2000 or reviewed by Brittany Harris?
SELECT DISTINCT T2.title FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID JOIN Reviewer AS T3 ON T1.rID = T3.rID WHERE T3.name = 'Brittany Harris' OR T2.year > 2000
extra
2,525
movie_1
[ "Movie", "Reviewer", "Rating" ]
What are the names of all movies that were made after 2000 or reviewed by Brittany Harris?
SELECT DISTINCT T2.title FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID JOIN Reviewer AS T3 ON T1.rID = T3.rID WHERE T3.name = 'Brittany Harris' OR T2.year > 2000
extra
2,526
movie_1
[ "Movie" ]
What are names of the movies that are either made before 1980 or directed by James Cameron?
SELECT title FROM Movie WHERE director = "James Cameron" OR YEAR < 1980
medium
2,527
movie_1
[ "Movie" ]
What are the names of all movies made before 1980 or had James Cameron as the director?
SELECT title FROM Movie WHERE director = "James Cameron" OR YEAR < 1980
medium
2,528
movie_1
[ "Reviewer", "Rating" ]
What are the names of reviewers who had rated 3 star and 4 star?
SELECT T2.name FROM Rating AS T1 JOIN Reviewer AS T2 ON T1.rID = T2.rID WHERE T1.stars = 3 INTERSECT SELECT T2.name FROM Rating AS T1 JOIN Reviewer AS T2 ON T1.rID = T2.rID WHERE T1.stars = 4
extra
2,529
movie_1
[ "Reviewer", "Rating" ]
What are the names of all reviewers that have given 3 or 4 stars for reviews?
SELECT T2.name FROM Rating AS T1 JOIN Reviewer AS T2 ON T1.rID = T2.rID WHERE T1.stars = 3 INTERSECT SELECT T2.name FROM Rating AS T1 JOIN Reviewer AS T2 ON T1.rID = T2.rID WHERE T1.stars = 4
extra
2,530
movie_1
[ "Movie", "Rating" ]
What are the names of movies that get 3 star and 4 star?
SELECT T2.title FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID WHERE T1.stars = 3 INTERSECT SELECT T2.title FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID WHERE T1.stars = 4
extra
2,531
movie_1
[ "Movie", "Rating" ]
What are the names of all movies that received 3 or 4 stars?
SELECT T2.title FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID WHERE T1.stars = 3 INTERSECT SELECT T2.title FROM Rating AS T1 JOIN Movie AS T2 ON T1.mID = T2.mID WHERE T1.stars = 4
extra
2,532
county_public_safety
[ "county_public_safety" ]
How many counties are there?
SELECT count(*) FROM county_public_safety
easy
2,533
county_public_safety
[ "county_public_safety" ]
Count the number of countries.
SELECT count(*) FROM county_public_safety
easy
2,534
county_public_safety
[ "county_public_safety" ]
List the names of counties in descending order of population.
SELECT Name FROM county_public_safety ORDER BY Population DESC
easy
2,535
county_public_safety
[ "county_public_safety" ]
What are the names of the counties of public safety, ordered by population descending?
SELECT Name FROM county_public_safety ORDER BY Population DESC
easy
2,536
county_public_safety
[ "county_public_safety" ]
List the distinct police forces of counties whose location is not on east side.
SELECT DISTINCT Police_force FROM county_public_safety WHERE LOCATION != "East"
easy
2,537
county_public_safety
[ "county_public_safety" ]
What are the different police forces of counties that are not located in the East?
SELECT DISTINCT Police_force FROM county_public_safety WHERE LOCATION != "East"
easy
2,538
county_public_safety
[ "county_public_safety" ]
What are the minimum and maximum crime rate of counties?
SELECT min(Crime_rate) , max(Crime_rate) FROM county_public_safety
medium
2,539
county_public_safety
[ "county_public_safety" ]
Return the minimum and maximum crime rates across all counties.
SELECT min(Crime_rate) , max(Crime_rate) FROM county_public_safety
medium
2,540
county_public_safety
[ "county_public_safety" ]
Show the crime rates of counties in ascending order of number of police officers.
SELECT Crime_rate FROM county_public_safety ORDER BY Police_officers ASC
easy
2,541
county_public_safety
[ "county_public_safety" ]
What are the crime rates of counties sorted by number of offices ascending?
SELECT Crime_rate FROM county_public_safety ORDER BY Police_officers ASC
easy
2,542
county_public_safety
[ "city" ]
What are the names of cities in ascending alphabetical order?
SELECT Name FROM city ORDER BY Name ASC
easy
2,543
county_public_safety
[ "city" ]
Return the names of cities, ordered alphabetically.
SELECT Name FROM city ORDER BY Name ASC
easy
2,544
county_public_safety
[ "city" ]
What are the percentage of hispanics in cities with the black percentage higher than 10?
SELECT Hispanic FROM city WHERE Black > 10
easy
2,545
county_public_safety
[ "city" ]
Return the hispanic percentage for cities in which the black percentage is greater than 10.
SELECT Hispanic FROM city WHERE Black > 10
easy
2,546
county_public_safety
[ "county_public_safety" ]
List the name of the county with the largest population.
SELECT Name FROM county_public_safety ORDER BY Population DESC LIMIT 1
medium
2,547
county_public_safety
[ "county_public_safety" ]
What is the name of the county with the greatest population?
SELECT Name FROM county_public_safety ORDER BY Population DESC LIMIT 1
medium
2,548
county_public_safety
[ "city" ]
List the names of the city with the top 5 white percentages.
SELECT Name FROM city ORDER BY White DESC LIMIT 5
medium
2,549
county_public_safety
[ "city" ]
What are the names of the five cities with the greatest proportion of white people?
SELECT Name FROM city ORDER BY White DESC LIMIT 5
medium
2,550
county_public_safety
[ "city", "county_public_safety" ]
Show names of cities and names of counties they are in.
SELECT T1.Name , T2.Name FROM city AS T1 JOIN county_public_safety AS T2 ON T1.County_ID = T2.County_ID
medium
2,551
county_public_safety
[ "city", "county_public_safety" ]
What are the names of cities, as well as the names of the counties they correspond to?
SELECT T1.Name , T2.Name FROM city AS T1 JOIN county_public_safety AS T2 ON T1.County_ID = T2.County_ID
medium
2,552
county_public_safety
[ "city", "county_public_safety" ]
Show white percentages of cities and the crime rates of counties they are in.
SELECT T1.White , T2.Crime_rate FROM city AS T1 JOIN county_public_safety AS T2 ON T1.County_ID = T2.County_ID
medium
2,553
county_public_safety
[ "city", "county_public_safety" ]
What are the white percentages of cities, and the corresponding crime rates of the counties they correspond to?
SELECT T1.White , T2.Crime_rate FROM city AS T1 JOIN county_public_safety AS T2 ON T1.County_ID = T2.County_ID
medium
2,554
county_public_safety
[ "city", "county_public_safety" ]
Show the name of cities in the county that has the largest number of police officers.
SELECT name FROM city WHERE county_ID = (SELECT county_ID FROM county_public_safety ORDER BY Police_officers DESC LIMIT 1)
hard
2,555
county_public_safety
[ "city", "county_public_safety" ]
What are the names of cities that are in the county with the most police officers?
SELECT name FROM city WHERE county_ID = (SELECT county_ID FROM county_public_safety ORDER BY Police_officers DESC LIMIT 1)
hard
2,556
county_public_safety
[ "city", "county_public_safety" ]
Show the number of cities in counties that have a population more than 20000.
SELECT count(*) FROM city WHERE county_ID IN (SELECT county_ID FROM county_public_safety WHERE population > 20000)
hard
2,557
county_public_safety
[ "city", "county_public_safety" ]
How many cities are in counties that have populations of over 20000?
SELECT count(*) FROM city WHERE county_ID IN (SELECT county_ID FROM county_public_safety WHERE population > 20000)
hard
2,558
county_public_safety
[ "city", "county_public_safety" ]
Show the crime rate of counties with a city having white percentage more than 90.
SELECT T2.Crime_rate FROM city AS T1 JOIN county_public_safety AS T2 ON T1.County_ID = T2.County_ID WHERE T1.White > 90
medium
2,559
county_public_safety
[ "city", "county_public_safety" ]
What are the crime rates of counties that contain cities that have white percentages of over 90?
SELECT T2.Crime_rate FROM city AS T1 JOIN county_public_safety AS T2 ON T1.County_ID = T2.County_ID WHERE T1.White > 90
medium
2,560
county_public_safety
[ "county_public_safety" ]
Please show the police forces and the number of counties with each police force.
SELECT Police_force , COUNT(*) FROM county_public_safety GROUP BY Police_force
medium
2,561
county_public_safety
[ "county_public_safety" ]
How many counties correspond to each police force?
SELECT Police_force , COUNT(*) FROM county_public_safety GROUP BY Police_force
medium
2,562
county_public_safety
[ "county_public_safety" ]
What is the location shared by most counties?
SELECT LOCATION FROM county_public_safety GROUP BY LOCATION ORDER BY COUNT(*) DESC LIMIT 1
hard
2,563
county_public_safety
[ "county_public_safety" ]
Which location has the most corresponding counties?
SELECT LOCATION FROM county_public_safety GROUP BY LOCATION ORDER BY COUNT(*) DESC LIMIT 1
hard
2,564
county_public_safety
[ "city", "county_public_safety" ]
List the names of counties that do not have any cities.
SELECT Name FROM county_public_safety WHERE County_ID NOT IN (SELECT County_ID FROM city)
hard
2,565
county_public_safety
[ "city", "county_public_safety" ]
What are the names of counties that do not contain any cities?
SELECT Name FROM county_public_safety WHERE County_ID NOT IN (SELECT County_ID FROM city)
hard
2,566
county_public_safety
[ "county_public_safety" ]
Show the police force shared by counties with location on the east and west.
SELECT Police_force FROM county_public_safety WHERE LOCATION = "East" INTERSECT SELECT Police_force FROM county_public_safety WHERE LOCATION = "West"
hard
2,567
county_public_safety
[ "county_public_safety" ]
Which police forces operate in both counties that are located in the East and in the West?
SELECT Police_force FROM county_public_safety WHERE LOCATION = "East" INTERSECT SELECT Police_force FROM county_public_safety WHERE LOCATION = "West"
hard
2,568
county_public_safety
[ "city", "county_public_safety" ]
Show the names of cities in counties that have a crime rate less than 100.
SELECT name FROM city WHERE county_id IN (SELECT county_id FROM county_public_safety WHERE Crime_rate < 100)
hard
2,569
county_public_safety
[ "city", "county_public_safety" ]
What are the names of cities that are in counties that have a crime rate below 100?
SELECT name FROM city WHERE county_id IN (SELECT county_id FROM county_public_safety WHERE Crime_rate < 100)
hard
2,570
county_public_safety
[ "county_public_safety" ]
Show the case burden of counties in descending order of population.
SELECT Case_burden FROM county_public_safety ORDER BY Population DESC
easy
2,571
county_public_safety
[ "county_public_safety" ]
What are the case burdens of counties, ordered descending by population?
SELECT Case_burden FROM county_public_safety ORDER BY Population DESC
easy
2,572
inn_1
[ "Rooms" ]
Find the names of all modern rooms with a base price below $160 and two beds.
SELECT roomName FROM Rooms WHERE basePrice < 160 AND beds = 2 AND decor = 'modern';
medium
2,573
inn_1
[ "Rooms" ]
What are the names of modern rooms that have a base price lower than $160 and two beds.
SELECT roomName FROM Rooms WHERE basePrice < 160 AND beds = 2 AND decor = 'modern';
medium
2,574
inn_1
[ "Rooms" ]
Find all the rooms that have a price higher than 160 and can accommodate more than 2 people. Report room names and ids.
SELECT roomName , RoomId FROM Rooms WHERE basePrice > 160 AND maxOccupancy > 2;
medium
2,575
inn_1
[ "Rooms" ]
What are the room names and ids of all the rooms that cost more than 160 and can accommodate more than two people.
SELECT roomName , RoomId FROM Rooms WHERE basePrice > 160 AND maxOccupancy > 2;
medium
2,576
inn_1
[ "Reservations", "Rooms" ]
Find the most popular room in the hotel. The most popular room is the room that had seen the largest number of reservations.
SELECT T2.roomName FROM Reservations AS T1 JOIN Rooms AS T2 ON T1.Room = T2.RoomId GROUP BY T1.Room ORDER BY count(*) DESC LIMIT 1;
extra
2,577
inn_1
[ "Reservations", "Rooms" ]
Which room has the largest number of reservations?
SELECT T2.roomName FROM Reservations AS T1 JOIN Rooms AS T2 ON T1.Room = T2.RoomId GROUP BY T1.Room ORDER BY count(*) DESC LIMIT 1;
extra
2,578
inn_1
[ "Reservations" ]
How many kids stay in the rooms reserved by ROY SWEAZY?
SELECT kids FROM Reservations WHERE FirstName = "ROY" AND LastName = "SWEAZY";
medium
2,579
inn_1
[ "Reservations" ]
Find the number of kids staying in the rooms reserved by a person called ROY SWEAZ.
SELECT kids FROM Reservations WHERE FirstName = "ROY" AND LastName = "SWEAZY";
medium
2,580
inn_1
[ "Reservations" ]
How many times does ROY SWEAZY has reserved a room.
SELECT count(*) FROM Reservations WHERE FirstName = "ROY" AND LastName = "SWEAZY";
medium
2,581
inn_1
[ "Reservations" ]
Find the number of times ROY SWEAZY has reserved a room.
SELECT count(*) FROM Reservations WHERE FirstName = "ROY" AND LastName = "SWEAZY";
medium
2,582
inn_1
[ "Reservations", "Rooms" ]
Which room has the highest rate? List the room's full name, rate, check in and check out date.
SELECT T2.roomName , T1.Rate , T1.CheckIn , T1.CheckOut FROM Reservations AS T1 JOIN Rooms AS T2 ON T1.Room = T2.RoomId GROUP BY T1.Room ORDER BY T1.Rate DESC LIMIT 1;
extra
2,583
inn_1
[ "Reservations", "Rooms" ]
Return the name, rate, check in and check out date for the room with the highest rate.
SELECT T2.roomName , T1.Rate , T1.CheckIn , T1.CheckOut FROM Reservations AS T1 JOIN Rooms AS T2 ON T1.Room = T2.RoomId GROUP BY T1.Room ORDER BY T1.Rate DESC LIMIT 1;
extra
2,584
inn_1
[ "Reservations" ]
How many adults stay in the room CONRAD SELBIG checked in on Oct 23, 2010?
SELECT Adults FROM Reservations WHERE CheckIn = "2010-10-23" AND FirstName = "CONRAD" AND LastName = "SELBIG";
medium
2,585
inn_1
[ "Reservations" ]
Find the number of adults for the room reserved and checked in by CONRAD SELBIG on Oct 23, 2010.
SELECT Adults FROM Reservations WHERE CheckIn = "2010-10-23" AND FirstName = "CONRAD" AND LastName = "SELBIG";
medium
2,586
inn_1
[ "Reservations" ]
How many kids stay in the room DAMIEN TRACHSEL checked in on Sep 21, 2010?
SELECT Kids FROM Reservations WHERE CheckIn = "2010-09-21" AND FirstName = "DAMIEN" AND LastName = "TRACHSEL";
medium
2,587
inn_1
[ "Reservations" ]
Return the number of kids for the room reserved and checked in by DAMIEN TRACHSEL on Sep 21, 2010.
SELECT Kids FROM Reservations WHERE CheckIn = "2010-09-21" AND FirstName = "DAMIEN" AND LastName = "TRACHSEL";
medium
2,588
inn_1
[ "Rooms" ]
How many king beds are there?
SELECT sum(beds) FROM Rooms WHERE bedtype = 'King';
easy
2,589
inn_1
[ "Rooms" ]
Find the total number of king beds available.
SELECT sum(beds) FROM Rooms WHERE bedtype = 'King';
easy
2,590
inn_1
[ "Rooms" ]
List the names and decor of rooms that have a king bed. Sort the list by their price.
SELECT roomName , decor FROM Rooms WHERE bedtype = 'King' ORDER BY basePrice;
medium
2,591
inn_1
[ "Rooms" ]
What are the names and decor of rooms with a king bed? Sort them by their price
SELECT roomName , decor FROM Rooms WHERE bedtype = 'King' ORDER BY basePrice;
medium
2,592
inn_1
[ "Rooms" ]
Which room has cheapest base price? List the room's name and the base price.
SELECT roomName , basePrice FROM Rooms ORDER BY basePrice ASC LIMIT 1;
medium
2,593
inn_1
[ "Rooms" ]
What are the room name and base price of the room with the lowest base price?
SELECT roomName , basePrice FROM Rooms ORDER BY basePrice ASC LIMIT 1;
medium
2,594
inn_1
[ "Rooms" ]
What is the decor of room Recluse and defiance?
SELECT decor FROM Rooms WHERE roomName = "Recluse and defiance";
easy
2,595
inn_1
[ "Rooms" ]
Return the decor of the room named "Recluse and defiance".
SELECT decor FROM Rooms WHERE roomName = "Recluse and defiance";
easy
2,596
inn_1
[ "Rooms" ]
What is the average base price of different bed type? List bed type and average base price.
SELECT bedType , avg(basePrice) FROM Rooms GROUP BY bedType;
medium
2,597
inn_1
[ "Rooms" ]
For each bed type, find the average base price of different bed type.
SELECT bedType , avg(basePrice) FROM Rooms GROUP BY bedType;
medium
2,598
inn_1
[ "Rooms" ]
What is the total number of people who could stay in the modern rooms in this inn?
SELECT sum(maxOccupancy) FROM Rooms WHERE decor = 'modern';
easy
2,599
inn_1
[ "Rooms" ]
How many people in total can stay in the modern rooms of this inn?
SELECT sum(maxOccupancy) FROM Rooms WHERE decor = 'modern';
easy