interaction_utterance
sequencelengths
0
6
interaction_query
sequencelengths
0
6
final_utterance
stringlengths
19
224
final_query
stringlengths
22
577
db_id
stringclasses
140 values
[ "Which trips have the oldest ids? Limit it to 3.", "Just show information on the start station and end station for those." ]
[ "SELECT * FROM trip ORDER BY id LIMIT 3", "SELECT start_station_name , end_station_name FROM trip ORDER BY id LIMIT 3" ]
Give me the start station and end station for the trips with the three oldest ids.
SELECT start_station_name , end_station_name FROM trip ORDER BY id LIMIT 3
bike_1
[ "Which stations are located in San Jose City?", "For those, which are their latitude and longitude?", "Take averages." ]
[ "SELECT name from station where city = \"San Jose\"", "SELECT lat, long FROM station WHERE city = \"San Jose\"", "SELECT avg(lat) , avg(long) FROM station WHERE city = \"San Jose\"" ]
What is the average latitude and longitude of stations located in San Jose city?
SELECT avg(lat) , avg(long) FROM station WHERE city = "San Jose"
bike_1
[ "Order the trips by duration, ascending.", "Limit it to the ids.", "Limit it to the shortest duration." ]
[ "SELECT * FROM trip ORDER BY duration", "SELECT id FROM trip ORDER BY duration", "SELECT id FROM trip ORDER BY duration LIMIT 1" ]
What is the id of the trip that has the shortest duration?
SELECT id FROM trip ORDER BY duration LIMIT 1
bike_1
[ "Show records of trips with bike id 636.", "just show the durations.", "Take a sum and max." ]
[ "SELECT * FROM trip WHERE bike_id = 636", "SELECT duration FROM trip WHERE bike_id = 636", "SELECT sum(duration) , max(duration) FROM trip WHERE bike_id = 636" ]
What is the total and maximum duration of trips with bike id 636?
SELECT sum(duration) , max(duration) FROM trip WHERE bike_id = 636
bike_1
[ "Show weather records from August.", "Just show the mean temperature in those records.", "Group by zipcode and average those records." ]
[ "SELECT * FROM weather WHERE date LIKE \"8/%\"", "SELECT mean_temperature_f FROM weather WHERE date LIKE \"8/%\"", "SELECT zip_code , avg(mean_temperature_f) FROM weather WHERE date LIKE \"8/%\" GROUP BY zip_code" ]
For each zip code, return the average mean temperature of August there.
SELECT zip_code , avg(mean_temperature_f) FROM weather WHERE date LIKE "8/%" GROUP BY zip_code
bike_1
[ "Which station ids ever had 7 bikes available?", "Give the names for those stations." ]
[ "SELECT DISTINCT station_id from status WHERE bikes_available = 7", "SELECT DISTINCT T1.name FROM station AS T1 JOIN status AS T2 ON T1.id = T2.station_id WHERE T2.bikes_available = 7" ]
Return the unique name for stations that have ever had 7 bikes available.
SELECT DISTINCT T1.name FROM station AS T1 JOIN status AS T2 ON T1.id = T2.station_id WHERE T2.bikes_available = 7
bike_1
[ "Show trip records from August.", "Limit that to the start station name and id.", "Which start station had the most trips starting from August? Give me the name and id of the station." ]
[ "SELECT * from trip WHERE start_date LIKE \"8/%\"", "SELECT start_station_name , start_station_id FROM trip WHERE start_date LIKE \"8/%\"", "SELECT start_station_name , start_station_id FROM trip WHERE start_date LIKE \"8/%\" GROUP BY start_station_name ORDER BY COUNT(*) DESC LIMIT 1" ]
Which start station had the most trips starting from August? Give me the name and id of the station.
SELECT start_station_name , start_station_id FROM trip WHERE start_date LIKE "8/%" GROUP BY start_station_name ORDER BY COUNT(*) DESC LIMIT 1
bike_1
[ "Show bike ids that traveled in zip code 94002.", "Which traveled there most often?" ]
[ "SELECT DISTINCT bike_id FROM trip WHERE zip_code = 94002", "SELECT bike_id FROM trip WHERE zip_code = 94002 GROUP BY bike_id ORDER BY COUNT(*) DESC LIMIT 1" ]
Which bike traveled the most often in zip code 94002?
SELECT bike_id FROM trip WHERE zip_code = 94002 GROUP BY bike_id ORDER BY COUNT(*) DESC LIMIT 1
bike_1
[ "Show the records of weather events with both mean humidity above 50 and mean visibility above 8.", "Count those days." ]
[ "SELECT * FROM weather WHERE mean_humidity > 50 AND mean_visibility_miles > 8", "SELECT COUNT(*) FROM weather WHERE mean_humidity > 50 AND mean_visibility_miles > 8" ]
How many days had both mean humidity above 50 and mean visibility above 8?
SELECT COUNT(*) FROM weather WHERE mean_humidity > 50 AND mean_visibility_miles > 8
bike_1
[ "Give records on the lengths of trips.", "Give records on the shortest trip.", "From which station id did it originate?", "For that start station id, give latitude, longitude, and city." ]
[ "SELECT duration from trip", "SELECT * from trip ORDER by duration limit 1", "SELECT start_station_id from trip ORDER by duration limit 1", "SELECT T1.lat , T1.long , T1.city FROM station AS T1 JOIN trip AS T2 ON T1.id = T2.start_station_id ORDER BY T2.duration LIMIT 1" ]
What is the latitude, longitude, city of the station from which the shortest trip started?
SELECT T1.lat , T1.long , T1.city FROM station AS T1 JOIN trip AS T2 ON T1.id = T2.start_station_id ORDER BY T2.duration LIMIT 1
bike_1
[ "Which station ids have average availability above 10?", "And which are located in San Francisco?", "Which pass both conditions?" ]
[ "SELECT DISTINCT station_id FROM status GROUP BY station_id HAVING avg(bikes_available) > 10", "SELECT DISTINCT id FROM station WHERE city = \"San Francisco\"", "SELECT id FROM station WHERE city = \"San Francisco\" INTERSECT SELECT station_id FROM status GROUP BY station_id HAVING avg(bikes_available) > 10" ]
What are the ids of stations that are located in San Francisco and have average bike availability above 10.
SELECT id FROM station WHERE city = "San Francisco" INTERSECT SELECT station_id FROM status GROUP BY station_id HAVING avg(bikes_available) > 10
bike_1
[ "Show records (name and id) of stations installed in December.", "Which had more than 14 bikes available?", "Union those two." ]
[ "SELECT name , id FROM station WHERE installation_date LIKE \"12/%\"", "SELECT T1.name , T1.id FROM station AS T1 JOIN status AS T2 ON T1.id = T2.station_id GROUP BY T2.station_id HAVING avg(T2.bikes_available) > 14", "SELECT T1.name , T1.id FROM station AS T1 JOIN status AS T2 ON T1.id = T2.station_id GROUP BY T2.station_id HAVING avg(T2.bikes_available) > 14 UNION SELECT name , id FROM station WHERE installation_date LIKE \"12/%\"" ]
What are the names and ids of stations that had more than 14 bikes available on average or were installed in December?
SELECT T1.name , T1.id FROM station AS T1 JOIN status AS T2 ON T1.id = T2.station_id GROUP BY T2.station_id HAVING avg(T2.bikes_available) > 14 UNION SELECT name , id FROM station WHERE installation_date LIKE "12/%"
bike_1
[ "Show records on cloud cover?", "Just for the zip code 94107.", "What is the 3 most common cloud cover rates in the region of zip code 94107?" ]
[ "SELECT cloud_cover FROM weather", "SELECT cloud_cover FROM weather WHERE zip_code = 94107", "SELECT cloud_cover FROM weather WHERE zip_code = 94107 GROUP BY cloud_cover ORDER BY COUNT (*) DESC LIMIT 3" ]
What is the 3 most common cloud cover rates in the region of zip code 94107?
SELECT cloud_cover FROM weather WHERE zip_code = 94107 GROUP BY cloud_cover ORDER BY COUNT (*) DESC LIMIT 3
bike_1
[ "Show the records on mean sea level pressure by zip code.", "Now group by zip code and average over the pressure.", "Which zip code has the lowest of those?" ]
[ "SELECT zip_code, mean_sea_level_pressure_inches FROM weather GROUP BY zip_code", "SELECT zip_code, avg(mean_sea_level_pressure_inches) FROM weather GROUP BY zip_code", "SELECT zip_code FROM weather GROUP BY zip_code ORDER BY avg(mean_sea_level_pressure_inches) LIMIT 1" ]
What is the zip code in which the average mean sea level pressure is the lowest?
SELECT zip_code FROM weather GROUP BY zip_code ORDER BY avg(mean_sea_level_pressure_inches) LIMIT 1
bike_1
[ "Which stations are located in \"Palo Alto\"?", "What is the average bike availability in stations that are not located in Palo Alto?" ]
[ "SELECT id FROM station WHERE city = \"Palo Alto\"", "SELECT avg(bikes_available) FROM status WHERE station_id NOT IN (SELECT id FROM station WHERE city = \"Palo Alto\")" ]
What is the average bike availability in stations that are not located in Palo Alto?
SELECT avg(bikes_available) FROM status WHERE station_id NOT IN (SELECT id FROM station WHERE city = "Palo Alto")
bike_1
[ "Which station ids ever had bike availability more than 10?", "Which did not?", "For those, take the average longitude." ]
[ "SELECT DISTINCT station_id FROM status GROUP BY station_id HAVING max(bikes_available) > 10", "SELECT id FROM station WHERE id NOT IN (SELECT station_id FROM status GROUP BY station_id HAVING max(bikes_available) > 10)", "SELECT avg(long) FROM station WHERE id NOT IN (SELECT station_id FROM status GROUP BY station_id HAVING max(bikes_available) > 10)" ]
What is the average longitude of stations that never had bike availability more than 10?
SELECT avg(long) FROM station WHERE id NOT IN (SELECT station_id FROM status GROUP BY station_id HAVING max(bikes_available) > 10)
bike_1
[ "Give zip codes from trips.", "Which zip codes had an average mean temperature greater than 60?", "Give me ids for all the trip that took place in a zip code area with average mean temperature above 60." ]
[ "SELECT DISTINCT zip_code from trip", "SELECT zip_code from weather group by zip_code HAVING avg(mean_temperature_f) > 60", "SELECT T1.id FROM trip AS T1 JOIN weather AS T2 ON T1.zip_code = T2.zip_code GROUP BY T2.zip_code HAVING avg(T2.mean_temperature_f) > 60" ]
Give me ids for all the trip that took place in a zip code area with average mean temperature above 60.
SELECT T1.id FROM trip AS T1 JOIN weather AS T2 ON T1.zip_code = T2.zip_code GROUP BY T2.zip_code HAVING avg(T2.mean_temperature_f) > 60
bike_1
[ "Give weather records with max wind speed greater than or equal to 25.", "Count the times that event occurred by zip code." ]
[ "SELECT * FROM weather WHERE max_wind_Speed_mph >= 25", "SELECT zip_code , count(*) FROM weather WHERE max_wind_Speed_mph >= 25 GROUP BY zip_code" ]
For each zip code, return how many times max wind speed reached 25?
SELECT zip_code , count(*) FROM weather WHERE max_wind_Speed_mph >= 25 GROUP BY zip_code
bike_1
[ "What is the minimum min dew point in zip code 94107?", "Give dates and zip codes with lower min dew points than that, even." ]
[ "SELECT min(min_dew_point_f) FROM weather WHERE zip_code = 94107", "SELECT date , zip_code FROM weather WHERE min_dew_point_f < (SELECT min(min_dew_point_f) FROM weather WHERE zip_code = 94107)" ]
On which day and in which zip code was the min dew point lower than any day in zip code 94107?
SELECT date , zip_code FROM weather WHERE min_dew_point_f < (SELECT min(min_dew_point_f) FROM weather WHERE zip_code = 94107)
bike_1
[ "Show the dock counts of stations.", "Which dock count is largest?", "Give the trip id of the trip that started there." ]
[ "SELECT name, dock_count from station", "SELECT name, dock_count from station ORDER by dock_count desc limit 1", "SELECT T1.id FROM trip AS T1 JOIN station AS T2 ON T1.start_station_id = T2.id ORDER BY T2.dock_count DESC LIMIT 1" ]
Which trip started from the station with the largest dock count? Give me the trip id.
SELECT T1.id FROM trip AS T1 JOIN station AS T2 ON T1.start_station_id = T2.id ORDER BY T2.dock_count DESC LIMIT 1
bike_1
[ "Which trips ended in San Francisco?", "Which did not?", "Count them." ]
[ "SELECT T1.id FROM trip AS T1 JOIN station AS T2 ON T1.end_station_id = T2.id WHERE T2.city = \"San Francisco\"", "SELECT T1.id FROM trip AS T1 JOIN station AS T2 ON T1.end_station_id = T2.id WHERE T2.city != \"San Francisco\"", "SELECT count(*) FROM trip AS T1 JOIN station AS T2 ON T1.end_station_id = T2.id WHERE T2.city != \"San Francisco\"" ]
Count the number of trips that did not end in San Francisco city.
SELECT count(*) FROM trip AS T1 JOIN station AS T2 ON T1.end_station_id = T2.id WHERE T2.city != "San Francisco"
bike_1
[ "Which weather events had Fog or Rain?", "Which had neither?", "Limit the search to zip code 94107.", "Just give the date." ]
[ "SELECT * FROM weather WHERE EVENTS = \"Fog\" OR EVENTS = \"Rain\"", "SELECT * FROM weather WHERE EVENTS != \"Fog\" AND EVENTS != \"Rain\"", "SELECT * FROM weather WHERE zip_code = 94107 AND EVENTS != \"Fog\" AND EVENTS != \"Rain\"", "SELECT date FROM weather WHERE zip_code = 94107 AND EVENTS != \"Fog\" AND EVENTS != \"Rain\"" ]
In zip code 94107, on which day neither Fog nor Rain was observed?
SELECT date FROM weather WHERE zip_code = 94107 AND EVENTS != "Fog" AND EVENTS != "Rain"
bike_1
[ "Which station ids ever had bike availability below 7?", "Which did not?", "Force those stations to additionally have latitude above 37.4." ]
[ "SELECT DISTINCT station_id FROM status GROUP BY station_id HAVING min(bikes_available) < 7", "SELECT id FROM station EXCEPT SELECT station_id FROM status GROUP BY station_id HAVING min(bikes_available) < 7", "SELECT id FROM station WHERE lat > 37.4 EXCEPT SELECT station_id FROM status GROUP BY station_id HAVING min(bikes_available) < 7" ]
What are the ids of stations that have latitude above 37.4 and never had bike availability below 7?
SELECT id FROM station WHERE lat > 37.4 EXCEPT SELECT station_id FROM status GROUP BY station_id HAVING min(bikes_available) < 7
bike_1
[ "Which stations are located in San Jose?", "What are names of stations that have average bike availability above 10 and are not located in San Jose city?" ]
[ "SELECT name FROM station WHERE city = \"San Jose\"", "SELECT T1.name FROM station AS T1 JOIN status AS T2 ON T1.id = T2.station_id GROUP BY T2.station_id HAVING avg(bikes_available) > 10 EXCEPT SELECT name FROM station WHERE city = \"San Jose\"" ]
What are names of stations that have average bike availability above 10 and are not located in San Jose city?
SELECT T1.name FROM station AS T1 JOIN status AS T2 ON T1.id = T2.station_id GROUP BY T2.station_id HAVING avg(bikes_available) > 10 EXCEPT SELECT name FROM station WHERE city = "San Jose"
bike_1
[ "Give name, latitude, and city from stations.", "Order that by latitude ascending.", "Just limit it to the lowest latitude." ]
[ "SELECT name , lat , city FROM station", "SELECT name , lat , city FROM station ORDER BY lat", "SELECT name , lat , city FROM station ORDER BY lat LIMIT 1" ]
What are the name, latitude, and city of the station with the lowest latitude?
SELECT name , lat , city FROM station ORDER BY lat LIMIT 1
bike_1
[ "Which dates had the largest max gust speed?", "Also give mean temperature and mean humidity.", "Give the top 3 days instead." ]
[ "SELECT date FROM weather ORDER BY max_gust_speed_mph DESC LIMIT 1", "SELECT date , mean_temperature_f , mean_humidity FROM weather ORDER BY max_gust_speed_mph DESC LIMIT 1", "SELECT date , mean_temperature_f , mean_humidity FROM weather ORDER BY max_gust_speed_mph DESC LIMIT 3" ]
What are the date, mean temperature and mean humidity for the top 3 days with the largest max gust speeds?
SELECT date , mean_temperature_f , mean_humidity FROM weather ORDER BY max_gust_speed_mph DESC LIMIT 3
bike_1
[ "Which city has the most stations?", "List the name and the number of stations for all the cities that have at least 15 stations." ]
[ "SELECT city FROM station GROUP BY city ORDER By count(*) DESC limit 1", "SELECT city , COUNT(*) FROM station GROUP BY city HAVING COUNT(*) >= 15" ]
List the name and the number of stations for all the cities that have at least 15 stations.
SELECT city , COUNT(*) FROM station GROUP BY city HAVING COUNT(*) >= 15
bike_1
[ "Give the ids of start stations together with the count of trips originated there.", "Show the id and name for those with count at least 200." ]
[ "SELECT start_station_id, count(*) from trip GROUP by start_station_id", "SELECT start_station_id , start_station_name FROM trip GROUP BY start_station_id HAVING COUNT(*) >= 200" ]
Find the ids and names of stations from which at least 200 trips started.
SELECT start_station_id , start_station_name FROM trip GROUP BY start_station_id HAVING COUNT(*) >= 200
bike_1
[ "Show the zip codes and average mean visibilities.", "Find the zip code in which the average mean visibility is lower than 10." ]
[ "SELECT zip_code, mean_visibility_miles from weather", "SELECT zip_code FROM weather GROUP BY zip_code HAVING avg(mean_visibility_miles) < 10" ]
Find the zip code in which the average mean visibility is lower than 10.
SELECT zip_code FROM weather GROUP BY zip_code HAVING avg(mean_visibility_miles) < 10
bike_1
[ "What is the highest latitude of any station?", "Show that for each city", "List all the cities in a decreasing order of each city's stations' highest latitude." ]
[ "SELECT max(lat) from station", "SELECT city, max(lat) from station group by city", "SELECT city FROM station GROUP BY city ORDER BY max(lat) DESC" ]
List all the cities in a decreasing order of each city's stations' highest latitude.
SELECT city FROM station GROUP BY city ORDER BY max(lat) DESC
bike_1
[ "Show dates ordered by descending cloud cover rate.", "Also show me the cloud cover rate.", "Only the top 5." ]
[ "SELECT date FROM weather ORDER BY cloud_cover", "SELECT date , cloud_cover FROM weather ORDER BY cloud_cover", "SELECT date , cloud_cover FROM weather ORDER BY cloud_cover DESC LIMIT 5" ]
What are the dates that had the top 5 cloud cover rates? Also tell me the cloud cover rate.
SELECT date , cloud_cover FROM weather ORDER BY cloud_cover DESC LIMIT 5
bike_1
[ "Show trip durations.", "What are the ids and durations of the trips with the top 3 durations?" ]
[ "SELECT duration FROM trip", "SELECT id , duration FROM trip ORDER BY duration DESC LIMIT 3" ]
What are the ids and durations of the trips with the top 3 durations?
SELECT id , duration FROM trip ORDER BY duration DESC LIMIT 3
bike_1
[ "Show the average duration of trips starting from each station id.", "For each station, return its longitude and the average duration of trips that started from the station." ]
[ "SELECT start_station_id, avg(duration) from trip group by start_station_id", "SELECT T1.name , T1.long , avg(T2.duration) FROM station AS T1 JOIN trip AS T2 ON T1.id = T2.start_station_id GROUP BY T2.start_station_id" ]
For each station, return its longitude and the average duration of trips that started from the station.
SELECT T1.name , T1.long , avg(T2.duration) FROM station AS T1 JOIN trip AS T2 ON T1.id = T2.start_station_id GROUP BY T2.start_station_id
bike_1
[ "Show the average duration of trips ending at each station id.", "For each station, find its latitude and the minimum duration of trips that ended at the station." ]
[ "SELECT end_station_id, avg(duration) from trip group by end_station_id", "SELECT T1.name , T1.lat , min(T2.duration) FROM station AS T1 JOIN trip AS T2 ON T1.id = T2.end_station_id GROUP BY T2.end_station_id" ]
For each station, find its latitude and the minimum duration of trips that ended at the station.
SELECT T1.name , T1.lat , min(T2.duration) FROM station AS T1 JOIN trip AS T2 ON T1.id = T2.end_station_id GROUP BY T2.end_station_id
bike_1
[ "Which zip codes ever had a max dew point reaching 70?", "Which did not?" ]
[ "SELECT DISTINCT zip_code FROM weather WHERE max_dew_point_f >= 70", "SELECT DISTINCT zip_code FROM weather EXCEPT SELECT DISTINCT zip_code FROM weather WHERE max_dew_point_f >= 70" ]
Find all the zip codes in which the max dew point have never reached 70.
SELECT DISTINCT zip_code FROM weather EXCEPT SELECT DISTINCT zip_code FROM weather WHERE max_dew_point_f >= 70
bike_1
[ "What was the average duration of trips in zip code 94103?", "Which ids of trips lasted at least that long?" ]
[ "SELECT avg(duration) FROM trip WHERE zip_code = 94103", "SELECT id FROM trip WHERE duration >= (SELECT avg(duration) FROM trip WHERE zip_code = 94103)" ]
Find the id for the trips that lasted at least as long as the average duration of trips in zip code 94103.
SELECT id FROM trip WHERE duration >= (SELECT avg(duration) FROM trip WHERE zip_code = 94103)
bike_1
[ "Show the min temperature and max temperature for each day.", "Order that by ascending order of difference between the max and min temperatures.", "Find the day in which the difference between the max temperature and min temperature was the smallest. Also report the difference." ]
[ "SELECT date, max_temperature_f, min_temperature_f from weather", "SELECT date, max_temperature_f, min_temperature_f from weather ORDER by max_temperature_f - min_temperature_f", "SELECT date , max_temperature_f - min_temperature_f FROM weather ORDER BY max_temperature_f - min_temperature_f LIMIT 1" ]
Find the day in which the difference between the max temperature and min temperature was the smallest. Also report the difference.
SELECT date , max_temperature_f - min_temperature_f FROM weather ORDER BY max_temperature_f - min_temperature_f LIMIT 1
bike_1
[ "Which station ids never had more than 12 bikes available?", "Which ones ever had more than 12 bikes available?", "What are the id and name of the stations that have ever had more than 12 bikes available?" ]
[ "SELECT DISTINCT station_id from status where station_id not in (SELECT station_id from status where bikes_available > 12)", "SELECT DISTINCT station_id from status where bikes_available > 12", "SELECT DISTINCT T1.id , T1.name FROM station AS T1 JOIN status AS T2 ON T1.id = T2.station_id WHERE T2.bikes_available > 12" ]
What are the id and name of the stations that have ever had more than 12 bikes available?
SELECT DISTINCT T1.id , T1.name FROM station AS T1 JOIN status AS T2 ON T1.id = T2.station_id WHERE T2.bikes_available > 12
bike_1
[ "Which zip code had at least 100 trips taking place there?", "Give me the zip code where the average mean humidity is below 70", "Intersect those." ]
[ "SELECT DISTINCT zip_code FROM trip GROUP BY zip_code HAVING count(*) >= 100", "SELECT zip_code FROM weather GROUP BY zip_code HAVING avg(mean_humidity) < 70", "SELECT zip_code FROM weather GROUP BY zip_code HAVING avg(mean_humidity) < 70 INTERSECT SELECT zip_code FROM trip GROUP BY zip_code HAVING count(*) >= 100" ]
Give me the zip code where the average mean humidity is below 70 and at least 100 trips took place.
SELECT zip_code FROM weather GROUP BY zip_code HAVING avg(mean_humidity) < 70 INTERSECT SELECT zip_code FROM trip GROUP BY zip_code HAVING count(*) >= 100
bike_1
[ "Which end station names have more than 100 trips ending there?", "Which station names are in city \"Palo Alto\"?", "Take set minus on the last two results: what are the names of stations that are located in Palo Alto city but have never been the ending point of trips more than 100 times?" ]
[ "SELECT DISTINCT end_station_name FROM trip GROUP BY end_station_name HAVING count(*) > 100", "SELECT name FROM station WHERE city = \"Palo Alto\"", "SELECT name FROM station WHERE city = \"Palo Alto\" EXCEPT SELECT end_station_name FROM trip GROUP BY end_station_name HAVING count(*) > 100" ]
What are the names of stations that are located in Palo Alto city but have never been the ending point of trips more than 100 times?
SELECT name FROM station WHERE city = "Palo Alto" EXCEPT SELECT end_station_name FROM trip GROUP BY end_station_name HAVING count(*) > 100
bike_1
[ "How many trips started from Mountain View city", "How many trips started from Mountain View city and ended at Palo Alto city?" ]
[ "SELECT count(*) FROM station AS T1 JOIN trip AS T2 JOIN station AS T3 JOIN trip AS T4 ON T1.id = T2.start_station_id AND T2.id = T4.id AND T3.id = T4.end_station_id WHERE T1.city = \"Mountain View\"", "SELECT count(*) FROM station AS T1 JOIN trip AS T2 JOIN station AS T3 JOIN trip AS T4 ON T1.id = T2.start_station_id AND T2.id = T4.id AND T3.id = T4.end_station_id WHERE T1.city = \"Mountain View\" AND T3.city = \"Palo Alto\"" ]
How many trips started from Mountain View city and ended at Palo Alto city?
SELECT count(*) FROM station AS T1 JOIN trip AS T2 JOIN station AS T3 JOIN trip AS T4 ON T1.id = T2.start_station_id AND T2.id = T4.id AND T3.id = T4.end_station_id WHERE T1.city = "Mountain View" AND T3.city = "Palo Alto"
bike_1
[ "Show all the information about the players.", "How many are there?" ]
[ "SELECT * FROM player", "SELECT count(*) FROM player" ]
How many players are there?
SELECT count(*) FROM player
riding_club
[ "What are the player names?", "How many vote does each player has?", "Who has the maximum vote?", "Order the names by number of vote in ascending order." ]
[ "SELECT Player_name FROM player", "SELECT Player_name,Votes FROM player", "SELECT Player_name FROM player ORDER BY Votes DESC limit 1", "SELECT Player_name FROM player ORDER BY Votes ASC" ]
List the names of players in ascending order of votes.
SELECT Player_name FROM player ORDER BY Votes ASC
riding_club
[ "Show the player names and the residences.", "Show the names and the occupation of each them." ]
[ "SELECT Player_name , residence FROM player", "SELECT Gender , Occupation FROM player" ]
What are the gender and occupation of players?
SELECT Gender , Occupation FROM player
riding_club
[ "Show the player names and the residences.", "Only keep those whose gender is male.", "Show the player names and the residences whose occupation is not \"Researcher\"." ]
[ "SELECT Player_name , residence FROM player", "SELECT Player_name , residence FROM player WHERE Gender = \"M\"", "SELECT Player_name , residence FROM player WHERE Occupation != \"Researcher\"" ]
List the name and residence for players whose occupation is not "Researcher".
SELECT Player_name , residence FROM player WHERE Occupation != "Researcher"
riding_club
[ "List the name and the sponsor name of each player.", "How many unique sponsor names are there?", "Which sponsor names support female players?", "What about supporting players whose residence is \"Brandon\" or \"Birtle\"?" ]
[ "SELECT Player_name, Sponsor_name FROM player", "SELECT count(DISTINCT Sponsor_name) FROM player", "SELECT Sponsor_name FROM player WHERE Gender = \"F\"", "SELECT Sponsor_name FROM player WHERE Residence = \"Brandon\" OR Residence = \"Birtle\"" ]
Show the names of sponsors of players whose residence is either "Brandon" or "Birtle".
SELECT Sponsor_name FROM player WHERE Residence = "Brandon" OR Residence = "Birtle"
riding_club
[ "What are the player names and their number of votes?", "Which one has the minimum vote?", "What about the one with the maximum vote?" ]
[ "SELECT Player_name, Votes FROM player", "SELECT Player_name FROM player ORDER BY Votes ASC LIMIT 1", "SELECT Player_name FROM player ORDER BY Votes DESC LIMIT 1" ]
What is the name of the player with the largest number of votes?
SELECT Player_name FROM player ORDER BY Votes DESC LIMIT 1
riding_club
[ "Show the unique occupation for the players?", "How many in total?", "How many are there in each occupation?" ]
[ "SELECT distinct Occupation FROM player", "SELECT count(distinct Occupation) FROM player", "SELECT Occupation , COUNT(*) FROM player GROUP BY Occupation" ]
Show different occupations along with the number of players in each occupation.
SELECT Occupation , COUNT(*) FROM player GROUP BY Occupation
riding_club
[ "Show the unique occupation for the players?", "How many in total?", "Which is the most popular occupation?" ]
[ "SELECT distinct Occupation FROM player", "SELECT count(distinct Occupation) FROM player", "SELECT Occupation FROM player GROUP BY Occupation ORDER BY COUNT(*) DESC LIMIT 1" ]
Please show the most common occupation of players.
SELECT Occupation FROM player GROUP BY Occupation ORDER BY COUNT(*) DESC LIMIT 1
riding_club
[ "Show the unique residences for the players?", "How many in total?", "Which residences have only one player?", "What about at least two?" ]
[ "SELECT distinct Residence FROM player", "SELECT count(distinct Residence) FROM player", "SELECT Residence FROM player GROUP BY Residence HAVING COUNT(*) = 1", "SELECT Residence FROM player GROUP BY Residence HAVING COUNT(*) >= 2" ]
Show the residences that have at least two players.
SELECT Residence FROM player GROUP BY Residence HAVING COUNT(*) >= 2
riding_club
[ "List the name and gender of players", "How many coaches are there?", "Show the name of each player and also the corresponding coach name of each." ]
[ "SELECT Player_name, Gender FROM player", "SELECT count(*) FROM coach", "SELECT T3.Player_name , T2.coach_name FROM player_coach AS T1 JOIN coach AS T2 ON T1.Coach_ID = T2.Coach_ID JOIN player AS T3 ON T1.Player_ID = T3.Player_ID" ]
Show the names of players and names of their coaches.
SELECT T3.Player_name , T2.coach_name FROM player_coach AS T1 JOIN coach AS T2 ON T1.Coach_ID = T2.Coach_ID JOIN player AS T3 ON T1.Player_ID = T3.Player_ID
riding_club
[ "Which coaches are rank in the 1st and 2nd place?", "Which coach is the 1st, show the name of the coach?", "What are the names of players of that coach?" ]
[ "SELECT Coach_name FROM coach where rank < 3", "SELECT Coach_name FROM coach where rank = 1", "SELECT T3.Player_name FROM player_coach AS T1 JOIN coach AS T2 ON T1.Coach_ID = T2.Coach_ID JOIN player AS T3 ON T1.Player_ID = T3.Player_ID WHERE T2.Rank = 1" ]
Show the names of players coached by the rank 1 coach.
SELECT T3.Player_name FROM player_coach AS T1 JOIN coach AS T2 ON T1.Coach_ID = T2.Coach_ID JOIN player AS T3 ON T1.Player_ID = T3.Player_ID WHERE T2.Rank = 1
riding_club
[ "List the name of players", "Show the name of each player and also the corresponding coach name.", "Which pair starts before 2012?", "What about after 2011?", "Only show the player names and genders of those results." ]
[ "SELECT Player_name FROM player", "SELECT T3.Player_name , T2.coach_name FROM player_coach AS T1 JOIN coach AS T2 ON T1.Coach_ID = T2.Coach_ID JOIN player AS T3 ON T1.Player_ID = T3.Player_ID", "SELECT T3.Player_name , T2.coach_name FROM player_coach AS T1 JOIN coach AS T2 ON T1.Coach_ID = T2.Coach_ID JOIN player AS T3 ON T1.Player_ID = T3.Player_ID WHERE T1.Starting_year < 2012", "SELECT T3.Player_name , T2.coach_name FROM player_coach AS T1 JOIN coach AS T2 ON T1.Coach_ID = T2.Coach_ID JOIN player AS T3 ON T1.Player_ID = T3.Player_ID WHERE T1.Starting_year > 2011", "SELECT T3.Player_name , T3.gender FROM player_coach AS T1 JOIN coach AS T2 ON T1.Coach_ID = T2.Coach_ID JOIN player AS T3 ON T1.Player_ID = T3.Player_ID WHERE T1.Starting_year > 2011" ]
Show the names and genders of players with a coach starting after 2011.
SELECT T3.Player_name , T3.gender FROM player_coach AS T1 JOIN coach AS T2 ON T1.Coach_ID = T2.Coach_ID JOIN player AS T3 ON T1.Player_ID = T3.Player_ID WHERE T1.Starting_year > 2011
riding_club
[ "List the name of players", "How many coaches in total?", "Show the name of each player and also the corresponding coach name of each.", "Who is Ross Eadie's coach?", "List all the player-coach name pair with the vote of players, in descending order." ]
[ "SELECT Player_name FROM player", "SELECT count(*) FROM coach", "SELECT T3.Player_name , T2.coach_name FROM player_coach AS T1 JOIN coach AS T2 ON T1.Coach_ID = T2.Coach_ID JOIN player AS T3 ON T1.Player_ID = T3.Player_ID", "SELECT T2.coach_name FROM player_coach AS T1 JOIN coach AS T2 ON T1.Coach_ID = T2.Coach_ID JOIN player AS T3 ON T1.Player_ID = T3.Player_ID where T3.Player_name = 'Ross Eadie'", "SELECT T3.Player_name , T2.coach_name FROM player_coach AS T1 JOIN coach AS T2 ON T1.Coach_ID = T2.Coach_ID JOIN player AS T3 ON T1.Player_ID = T3.Player_ID ORDER BY T3.Votes DESC" ]
Show the names of players and names of their coaches in descending order of the votes of players.
SELECT T3.Player_name , T2.coach_name FROM player_coach AS T1 JOIN coach AS T2 ON T1.Coach_ID = T2.Coach_ID JOIN player AS T3 ON T1.Player_ID = T3.Player_ID ORDER BY T3.Votes DESC
riding_club
[ "How many players are there?", "What about coaches?", "Which players do not have a coach?" ]
[ "SELECT count(*) FROM player", "SELECT count(*) FROM coach", "SELECT Player_name FROM player WHERE Player_ID NOT IN (SELECT Player_ID FROM player_coach)" ]
List the names of players that do not have coaches.
SELECT Player_name FROM player WHERE Player_ID NOT IN (SELECT Player_ID FROM player_coach)
riding_club
[ "How many female players are there?", "What about male players?", "What are the residences of them?", "Which residences have both female and male players?" ]
[ "SELECT count(*) FROM player where gender = 'F'", "SELECT count(*) FROM player where gender = 'M'", "SELECT Residence FROM player where gender = 'M'", "SELECT Residence FROM player WHERE gender = \"M\" INTERSECT SELECT Residence FROM player WHERE gender = \"F\"" ]
Show the residences that have both a player of gender "M" and a player of gender "F".
SELECT Residence FROM player WHERE gender = "M" INTERSECT SELECT Residence FROM player WHERE gender = "F"
riding_club
[ "How many clubs are there?", "How many coaches in total?", "How many coaches are there from 'AIK' club?", "How many coaches in each club, give the club id, club name and number of coaches." ]
[ "SELECT count(club_id) FROM club", "SELECT count(*) FROM coach", "SELECT count(*) FROM coach as T1 join club as T2 on T1.club_id = T2.club_id where T2.club_name = \"AIK\"", "SELECT T1.club_id , T1.club_name, count(*) FROM club AS T1 JOIN coach AS T2 ON T1.club_id = T2.club_id GROUP BY T1.club_id" ]
How many coaches does each club has? List the club id, name and the number of coaches.
SELECT T1.club_id , T1.club_name, count(*) FROM club AS T1 JOIN coach AS T2 ON T1.club_id = T2.club_id GROUP BY T1.club_id
riding_club
[ "List all the railways.", "How many in total?" ]
[ "SELECT * FROM railway", "SELECT count(*) FROM railway" ]
How many railways are there?
SELECT count(*) FROM railway
railway
[ "Show all the builders of the railway.", "Order them in ascending alphabetical order." ]
[ "SELECT Builder FROM railway", "SELECT Builder FROM railway ORDER BY Builder ASC" ]
List the builders of railways in ascending alphabetical order.
SELECT Builder FROM railway ORDER BY Builder ASC
railway
[ "Show the wheels and also locations of each railway." ]
[ "SELECT Wheels , LOCATION FROM railway" ]
List the wheels and locations of the railways.
SELECT Wheels , LOCATION FROM railway
railway
[ "Show all the level of managers.", "What is the average level?", "What is that of the managers that come from \"United States\"?", "What is the maximum level of managers that do not come from \"Australia\"?" ]
[ "SELECT LEVEL FROM manager", "SELECT avg(LEVEL) FROM manager", "SELECT avg(LEVEL) FROM manager WHERE Country != \"United States\"", "SELECT max(LEVEL) FROM manager WHERE Country != \"Australia\t\"" ]
What is the maximum level of managers in countries that are not "Australia"?
SELECT max(LEVEL) FROM manager WHERE Country != "Australia "
railway
[ "List all the ages of the managers", "What is the maximum value of it?", "How about the average?" ]
[ "SELECT Age FROM manager", "SELECT max(Age) FROM manager", "SELECT avg(Age) FROM manager" ]
What is the average age for all managers?
SELECT avg(Age) FROM manager
railway
[ "Show the names and levels of all managers.", "Only keep the name whose level is at least 7", "Order all the names in ascending order of level." ]
[ "SELECT Name, Level FROM manager", "SELECT Name FROM manager WHERE LEVEL >= 7", "SELECT Name FROM manager ORDER BY LEVEL ASC" ]
What are the names of managers in ascending order of level?
SELECT Name FROM manager ORDER BY LEVEL ASC
railway
[ "Show the names of the trains.", "Add the arrival time for each of them." ]
[ "SELECT Name FROM train", "SELECT Name , Arrival FROM train" ]
What are the names and arrival times of trains?
SELECT Name , Arrival FROM train
railway
[ "Show the names and ages of all managers.", "Only keep the ones whose level is at least 5.", "Order all the names in descending order of the age.", "Who is the oldest manager?" ]
[ "SELECT Name, Age FROM manager", "SELECT Name FROM manager WHERE LEVEL >= 5", "SELECT Name FROM manager ORDER BY Age DESC", "SELECT Name FROM manager ORDER BY Age DESC LIMIT 1" ]
What is the name of the oldest manager?
SELECT Name FROM manager ORDER BY Age DESC LIMIT 1
railway
[ "List the names of the trains.", "Add the locations to each." ]
[ "SELECT Name FROM train", "SELECT T2.Name , T1.Location FROM railway AS T1 JOIN train AS T2 ON T1.Railway_ID = T2.Railway_ID" ]
Show the names of trains and locations of railways they are in.
SELECT T2.Name , T1.Location FROM railway AS T1 JOIN train AS T2 ON T1.Railway_ID = T2.Railway_ID
railway
[ "List the train information with the name \"Andaman Exp\".", "Which railway is it? Show the railway name.", "And which builder is it?" ]
[ "SELECT * FROM train WHERE Name = \"Andaman Exp\"", "SELECT T1.Railway FROM railway AS T1 JOIN train AS T2 ON T1.Railway_ID = T2.Railway_ID WHERE T2.Name = \"Andaman Exp\"", "SELECT T1.Builder FROM railway AS T1 JOIN train AS T2 ON T1.Railway_ID = T2.Railway_ID WHERE T2.Name = \"Andaman Exp\"" ]
Show the builder of railways associated with the trains named "Andaman Exp".
SELECT T1.Builder FROM railway AS T1 JOIN train AS T2 ON T1.Railway_ID = T2.Railway_ID WHERE T2.Name = "Andaman Exp"
railway
[ "Show the builders of the railways.", "List the railway id and the location of each railway.", "Only keep the ones that are associated with more than one train." ]
[ "SELECT Builder FROM railway", "SELECT T2.Railway_ID , T1.Location FROM railway AS T1 JOIN train AS T2 ON T1.Railway_ID = T2.Railway_ID", "SELECT T2.Railway_ID , T1.Location FROM railway AS T1 JOIN train AS T2 ON T1.Railway_ID = T2.Railway_ID GROUP BY T2.Railway_ID HAVING COUNT(*) > 1" ]
Show id and location of railways that are associated with more than one train.
SELECT T2.Railway_ID , T1.Location FROM railway AS T1 JOIN train AS T2 ON T1.Railway_ID = T2.Railway_ID GROUP BY T2.Railway_ID HAVING COUNT(*) > 1
railway
[ "Show the builders of the railways.", "List the railway id and the builder for each one.", "Among those results, keep the one that associated with the most trains." ]
[ "SELECT Builder FROM railway", "SELECT T2.Railway_ID , T1.Builder FROM railway AS T1 JOIN train AS T2 ON T1.Railway_ID = T2.Railway_ID", "SELECT T2.Railway_ID , T1.Builder FROM railway AS T1 JOIN train AS T2 ON T1.Railway_ID = T2.Railway_ID GROUP BY T2.Railway_ID ORDER BY COUNT(*) DESC LIMIT 1" ]
Show the id and builder of the railway that are associated with the most trains.
SELECT T2.Railway_ID , T1.Builder FROM railway AS T1 JOIN train AS T2 ON T1.Railway_ID = T2.Railway_ID GROUP BY T2.Railway_ID ORDER BY COUNT(*) DESC LIMIT 1
railway
[ "List all the builders about the railways.", "Show each one and the corresponding counts of railways." ]
[ "SELECT Builder FROM railway", "SELECT Builder, count(*) FROM railway GROUP BY LOCATION" ]
Show different builders of railways, along with the corresponding number of railways using each builder.
SELECT Builder , COUNT(*) FROM railway GROUP BY Builder
railway
[ "List all the builders.", "Show the builders and the corresponding counts of each.", "Which one is the most popular one?" ]
[ "SELECT Builder FROM railway", "SELECT Builder, count(*) FROM railway GROUP BY LOCATION", "SELECT Builder FROM railway GROUP BY Builder ORDER BY COUNT(*) DESC LIMIT 1" ]
Show the most common builder of railways.
SELECT Builder FROM railway GROUP BY Builder ORDER BY COUNT(*) DESC LIMIT 1
railway
[ "List all the locations.", "Which ones have more than one railways?", "Show the locations and the corresponding counts of each." ]
[ "SELECT LOCATION FROM railway", "SELECT LOCATION FROM railway GROUP BY LOCATION HAVING COUNT(*) > 1", "SELECT LOCATION, count(*) FROM railway GROUP BY LOCATION" ]
Show different locations of railways along with the corresponding number of railways at each location.
SELECT LOCATION , COUNT(*) FROM railway GROUP BY LOCATION
railway
[ "List all the locations.", "What are the corresponding counts of railways?", "Which locations have more than one railways?" ]
[ "SELECT LOCATION FROM railway", "SELECT LOCATION, count(*) FROM railway GROUP BY LOCATION", "SELECT LOCATION FROM railway GROUP BY LOCATION HAVING COUNT(*) > 1" ]
Show the locations that have more than one railways.
SELECT LOCATION FROM railway GROUP BY LOCATION HAVING COUNT(*) > 1
railway
[ "Show all the information about each railway.", "What are the object numbers?", "Which of the railway has no trains, keep the object number." ]
[ "SELECT * FROM railway", "SELECT ObjectNumber FROM railway", "SELECT ObjectNumber FROM railway WHERE Railway_ID NOT IN (SELECT Railway_ID FROM train)" ]
List the object number of railways that do not have any trains.
SELECT ObjectNumber FROM railway WHERE Railway_ID NOT IN (SELECT Railway_ID FROM train)
railway
[ "List all the countries of the managers.", "How many are there?", "Keep the ones where the manager age is in the range of 50 and 46", "What about the other countries?" ]
[ "SELECT Country FROM manager", "SELECT count (DISTINCT Country) FROM manager", "SELECT Country FROM manager WHERE Age < 50 INTERSECT SELECT Country FROM manager WHERE Age > 46", "SELECT Country FROM manager WHERE Age > 50 INTERSECT SELECT Country FROM manager WHERE Age < 46" ]
Show the countries that have both managers of age above 50 and managers of age below 46.
SELECT Country FROM manager WHERE Age > 50 INTERSECT SELECT Country FROM manager WHERE Age < 46
railway
[ "List all the countries of the managers.", "How many unique ones are there?" ]
[ "SELECT Country FROM manager", "SELECT count (DISTINCT Country) FROM manager" ]
Show the distinct countries of managers.
SELECT DISTINCT Country FROM manager
railway
[ "List the manager names and the working years.", "Which is the maximum working years?", "Order the working years by the manager level." ]
[ "SELECT Name, Working_year_starts FROM manager", "SELECT max(Working_year_starts) FROM manager", "SELECT Working_year_starts FROM manager ORDER BY LEVEL DESC" ]
Show the working years of managers in descending order of their level.
SELECT Working_year_starts FROM manager ORDER BY LEVEL DESC
railway
[ "List all the climber information.", "How many records are there?" ]
[ "SELECT * FROM climber", "SELECT count(*) FROM climber" ]
How many climbers are there?
SELECT count(*) FROM climber
climbing
[ "What are the names of the climbers?", "Keep the ones whose point is at least 6?", "Order all the climber names in descending order of points." ]
[ "SELECT Name FROM climber", "SELECT Name FROM climber where Points >= 6", "SELECT Name FROM climber ORDER BY Points DESC" ]
List the names of climbers in descending order of points.
SELECT Name FROM climber ORDER BY Points DESC
climbing
[ "What are the names of the climbers?", "Keep the ones whose point is at least 4.6?", "Keep the ones whose country is \"West Germany\".", "What about the ones whose country is not \"Switzerland\"?" ]
[ "SELECT Name FROM climber", "SELECT Name FROM climber where Points >= 4.6", "SELECT Name FROM climber WHERE Country = \"West Germany\"", "SELECT Name FROM climber WHERE Country != \"Switzerland\"" ]
List the names of climbers whose country is not Switzerland.
SELECT Name FROM climber WHERE Country != "Switzerland"
climbing
[ "Which climber comes from Switzerland?", "What about United Kingdom?", "List all the points of those climber.", "What is the maximum point number?" ]
[ "SELECT Name FROM climber WHERE Country = \"Switzerland\"", "SELECT Name FROM climber WHERE Country != \"United Kingdom\"", "SELECT Points FROM climber WHERE Country != \"United Kingdom\"", "SELECT max(Points) FROM climber WHERE Country = \"United Kingdom\"" ]
What is the maximum point for climbers whose country is United Kingdom?
SELECT max(Points) FROM climber WHERE Country = "United Kingdom"
climbing
[ "List all the countries of the climbers.", "How many unique countries are there?" ]
[ "SELECT Country FROM climber", "SELECT COUNT(DISTINCT Country) FROM climber" ]
How many distinct countries are the climbers from?
SELECT COUNT(DISTINCT Country) FROM climber
climbing
[ "Show all the information about the mountains.", "List those results in ascending alphabetical order by the mountain names.", "What are the mountain names from those results?" ]
[ "SELECT * FROM mountain", "SELECT * FROM mountain ORDER BY Name ASC", "SELECT Name FROM mountain ORDER BY Name ASC" ]
What are the names of mountains in ascending alphabetical order?
SELECT Name FROM mountain ORDER BY Name ASC
climbing
[ "List all the countries of the mountains.", "Keep the ones that the mountain height is more than 4985.0.", "What about the height is more than 5000?" ]
[ "SELECT Country FROM mountain", "SELECT Country FROM mountain WHERE Height > 4985.0", "SELECT Country FROM mountain WHERE Height > 5000" ]
What are the countries of mountains with height bigger than 5000?
SELECT Country FROM mountain WHERE Height > 5000
climbing
[ "List all the names of the mountains.", "Keep the ones that the mountain Prominence is more than 900.0.", "So which mountain is the highest one?" ]
[ "SELECT Name FROM mountain", "SELECT Name FROM mountain WHERE Prominence > 900.0", "SELECT Name FROM mountain ORDER BY Height DESC LIMIT 1" ]
What is the name of the highest mountain?
SELECT Name FROM mountain ORDER BY Height DESC LIMIT 1
climbing
[ "List all the ranges of the mountains.", "Order those results by Prominence in descending order.", "Which one is the top one?", "What about top 3?" ]
[ "SELECT Range FROM mountain", "SELECT DISTINCT Range FROM mountain ORDER BY Prominence DESC", "SELECT DISTINCT Range FROM mountain ORDER BY Prominence DESC LIMIT 1", "SELECT DISTINCT Range FROM mountain ORDER BY Prominence DESC LIMIT 3" ]
List the distinct ranges of the mountains with the top 3 prominence.
SELECT DISTINCT Range FROM mountain ORDER BY Prominence DESC LIMIT 3
climbing
[ "List all the climber names", "Show the mountain names for those climbers." ]
[ "SELECT Name FROM climber mountain", "SELECT T1.Name , T2.Name FROM climber AS T1 JOIN mountain AS T2 ON T1.Mountain_ID = T2.Mountain_ID" ]
Show names of climbers and the names of mountains they climb.
SELECT T1.Name , T2.Name FROM climber AS T1 JOIN mountain AS T2 ON T1.Mountain_ID = T2.Mountain_ID
climbing
[ "Show all the climber names", "Also show the mountain height for those climbers." ]
[ "SELECT Name FROM climber mountain", "SELECT T1.Name , T2.Height FROM climber AS T1 JOIN mountain AS T2 ON T1.Mountain_ID = T2.Mountain_ID" ]
Show the names of climbers and the heights of mountains they climb.
SELECT T1.Name , T2.Height FROM climber AS T1 JOIN mountain AS T2 ON T1.Mountain_ID = T2.Mountain_ID
climbing
[ "Which climbers have the point to be 8.0", "Which one has the minimum point?", "What about the maximum?", "Show the mountain height of the mountain that climber has climbed." ]
[ "SELECT Name FROM climber WHERE Points = 8.0", "SELECT Name FROM climber ORDER BY Points ASC LIMIT 1", "SELECT Name FROM climber ORDER BY Points DESC LIMIT 1", "SELECT T2.Height FROM climber AS T1 JOIN mountain AS T2 ON T1.Mountain_ID = T2.Mountain_ID ORDER BY T1.Points DESC LIMIT 1" ]
Show the height of the mountain climbed by the climber with the maximum points.
SELECT T2.Height FROM climber AS T1 JOIN mountain AS T2 ON T1.Mountain_ID = T2.Mountain_ID ORDER BY T1.Points DESC LIMIT 1
climbing
[ "List all the climber names who come from \"United Kingdom\".", "What about from \"West Germany\"", "Show the mountains they have climbed." ]
[ "SELECT Name FROM climber WHERE Country = \"United Kingdom\"", "SELECT Name FROM climber WHERE Country = \"West Germany\"", "SELECT DISTINCT T2.Name FROM climber AS T1 JOIN mountain AS T2 ON T1.Mountain_ID = T2.Mountain_ID WHERE T1.Country = \"West Germany\"" ]
Show the distinct names of mountains climbed by climbers from country "West Germany".
SELECT DISTINCT T2.Name FROM climber AS T1 JOIN mountain AS T2 ON T1.Mountain_ID = T2.Mountain_ID WHERE T1.Country = "West Germany"
climbing
[ "How many countries are there?", "How many mountains are there in Tanzania?", "What about in Uganda?", "List the times used by the climbers for those mountains." ]
[ "SELECT count(*) FROM mountain", "SELECT count(*) FROM mountain where country = 'Tanzania'", "SELECT count(*) FROM mountain where country = 'Uganda'", "SELECT T1.Time FROM climber AS T1 JOIN mountain AS T2 ON T1.Mountain_ID = T2.Mountain_ID WHERE T2.Country = \"Uganda\"" ]
Show the times used by climbers to climb mountains in Country Uganda.
SELECT T1.Time FROM climber AS T1 JOIN mountain AS T2 ON T1.Mountain_ID = T2.Mountain_ID WHERE T2.Country = "Uganda"
climbing
[ "How many unique countries in total?", "Show the countries with the number of mountains for each of them." ]
[ "SELECT count( DISTINCT Country) FROM mountain", "SELECT Country, count(*) FROM mountain GROUP BY Country" ]
Please show the countries and the number of climbers from each country.
SELECT Country , COUNT(*) FROM climber GROUP BY Country
climbing
[ "How many countries in total?", "List the countries with the number of mountains for each.", "Keep the country names that have only one mountain.", "How about more than one mountain?" ]
[ "SELECT count( DISTINCT Country) FROM mountain", "SELECT Country, count(*) FROM mountain GROUP BY Country", "SELECT Country FROM mountain GROUP BY Country HAVING COUNT(*) = 1", "SELECT Country FROM mountain GROUP BY Country HAVING COUNT(*) > 1" ]
List the countries that have more than one mountain.
SELECT Country FROM mountain GROUP BY Country HAVING COUNT(*) > 1
climbing
[ "List the names of all the mountains", "Which of those has no climbers?" ]
[ "SELECT Name FROM mountain", "SELECT Name FROM mountain WHERE Mountain_ID NOT IN (SELECT Mountain_ID FROM climber)" ]
List the names of mountains that do not have any climber.
SELECT Name FROM mountain WHERE Mountain_ID NOT IN (SELECT Mountain_ID FROM climber)
climbing
[ "List all the countries of the mountains.", "Keep the ones that the mountain height is more than 4985.0.", "What about the height is more than 5600?", "Keep the country names where the mountain height is within the range of 5200 to 5600." ]
[ "SELECT Country FROM mountain", "SELECT Country FROM mountain WHERE Height > 4985.0", "SELECT Country FROM mountain WHERE Height > 5600", "SELECT Country FROM mountain WHERE Height > 5600 INTERSECT SELECT Country FROM mountain WHERE Height < 5200" ]
Show the countries that have mountains with height more than 5600 stories and mountains with height less than 5200.
SELECT Country FROM mountain WHERE Height > 5600 INTERSECT SELECT Country FROM mountain WHERE Height < 5200
climbing
[ "List all the ranges of mountains.", "How many unique ranges are there?", "How many mountains in each range?", "Which one has the largest number of mountains?" ]
[ "SELECT Range FROM mountain", "SELECT count(DISTINCT Range) FROM mountain", "SELECT Range, count (*) FROM mountain GROUP BY Range", "SELECT Range FROM mountain GROUP BY Range ORDER BY COUNT(*) DESC LIMIT 1" ]
Show the range that has the most number of mountains.
SELECT Range FROM mountain GROUP BY Range ORDER BY COUNT(*) DESC LIMIT 1
climbing
[ "List all the devices", "How many are there?" ]
[ "SELECT * FROM device", "SELECT count(*) FROM device" ]
How many devices are there?
SELECT count(*) FROM device
device
[ "List all the carrier names of each device", "How many are there?", "Order the carrier names in ascending order." ]
[ "SELECT Carrier FROM device", "SELECT count (DISTINCT Carrier) FROM device", "SELECT Carrier FROM device ORDER BY Carrier ASC" ]
List the carriers of devices in ascending alphabetical order.
SELECT Carrier FROM device ORDER BY Carrier ASC
device
[ "List the carrier name and software platform of each device", "How many of them use Android as software platform?", "What about not Android?", "What are the carrier names of them?" ]
[ "SELECT Carrier, Software_Platform FROM device", "SELECT count(*) FROM device where Software_Platform = 'Android'", "SELECT count(*) FROM device where Software_Platform != 'Android'", "SELECT Carrier FROM device WHERE Software_Platform != 'Android'" ]
What are the carriers of devices whose software platforms are not "Android"?
SELECT Carrier FROM device WHERE Software_Platform != 'Android'
device
[ "List the shop names and their open year.", "Keep the shop names, then show those names in ascending order of open year." ]
[ "SELECT Shop_Name, Open_Year FROM shop", "SELECT Shop_Name FROM shop ORDER BY Open_Year ASC" ]
What are the names of shops in ascending order of open year?
SELECT Shop_Name FROM shop ORDER BY Open_Year ASC
device