db_id stringclasses 140
values | question stringlengths 16 224 | query stringlengths 18 577 | db_schema stringclasses 140
values | question_toks listlengths 4 44 |
|---|---|---|---|---|
match_season | Show the name of colleges that have at least two players. | SELECT College FROM match_season GROUP BY College HAVING count(*) >= 2 | country: Country_id (number), Country_name (text), Capital (text), Official_native_language (text) | team: Team_id (number), Name (text) | match_season: Season (number), Player (text), Position (text), Country (number), Team (number), Draft_Pick_Number (number), Draft_Class (text), College (text) | player: Player_ID (n... | [
"Show",
"the",
"name",
"of",
"colleges",
"that",
"have",
"at",
"least",
"two",
"players",
"."
] |
match_season | What are the names of all colleges that have two or more players? | SELECT College FROM match_season GROUP BY College HAVING count(*) >= 2 | country: Country_id (number), Country_name (text), Capital (text), Official_native_language (text) | team: Team_id (number), Name (text) | match_season: Season (number), Player (text), Position (text), Country (number), Team (number), Draft_Pick_Number (number), Draft_Class (text), College (text) | player: Player_ID (n... | [
"What",
"are",
"the",
"names",
"of",
"all",
"colleges",
"that",
"have",
"two",
"or",
"more",
"players",
"?"
] |
match_season | Show the name of colleges that have at least two players in descending alphabetical order. | SELECT College FROM match_season GROUP BY College HAVING count(*) >= 2 ORDER BY College DESC | country: Country_id (number), Country_name (text), Capital (text), Official_native_language (text) | team: Team_id (number), Name (text) | match_season: Season (number), Player (text), Position (text), Country (number), Team (number), Draft_Pick_Number (number), Draft_Class (text), College (text) | player: Player_ID (n... | [
"Show",
"the",
"name",
"of",
"colleges",
"that",
"have",
"at",
"least",
"two",
"players",
"in",
"descending",
"alphabetical",
"order",
"."
] |
match_season | What are the names of colleges that have two or more players, listed in descending alphabetical order? | SELECT College FROM match_season GROUP BY College HAVING count(*) >= 2 ORDER BY College DESC | country: Country_id (number), Country_name (text), Capital (text), Official_native_language (text) | team: Team_id (number), Name (text) | match_season: Season (number), Player (text), Position (text), Country (number), Team (number), Draft_Pick_Number (number), Draft_Class (text), College (text) | player: Player_ID (n... | [
"What",
"are",
"the",
"names",
"of",
"colleges",
"that",
"have",
"two",
"or",
"more",
"players",
",",
"listed",
"in",
"descending",
"alphabetical",
"order",
"?"
] |
match_season | What are the names of teams that do no have match season record? | SELECT Name FROM team WHERE Team_id NOT IN (SELECT Team FROM match_season) | country: Country_id (number), Country_name (text), Capital (text), Official_native_language (text) | team: Team_id (number), Name (text) | match_season: Season (number), Player (text), Position (text), Country (number), Team (number), Draft_Pick_Number (number), Draft_Class (text), College (text) | player: Player_ID (n... | [
"What",
"are",
"the",
"names",
"of",
"teams",
"that",
"do",
"no",
"have",
"match",
"season",
"record",
"?"
] |
match_season | Return the names of teams that have no match season record. | SELECT Name FROM team WHERE Team_id NOT IN (SELECT Team FROM match_season) | country: Country_id (number), Country_name (text), Capital (text), Official_native_language (text) | team: Team_id (number), Name (text) | match_season: Season (number), Player (text), Position (text), Country (number), Team (number), Draft_Pick_Number (number), Draft_Class (text), College (text) | player: Player_ID (n... | [
"Return",
"the",
"names",
"of",
"teams",
"that",
"have",
"no",
"match",
"season",
"record",
"."
] |
match_season | What are the names of countries that have both players with position forward and players with position defender? | SELECT T1.Country_name FROM country AS T1 JOIN match_season AS T2 ON T1.Country_id = T2.Country WHERE T2.Position = "Forward" INTERSECT SELECT T1.Country_name FROM country AS T1 JOIN match_season AS T2 ON T1.Country_id = T2.Country WHERE T2.Position = "Defender" | country: Country_id (number), Country_name (text), Capital (text), Official_native_language (text) | team: Team_id (number), Name (text) | match_season: Season (number), Player (text), Position (text), Country (number), Team (number), Draft_Pick_Number (number), Draft_Class (text), College (text) | player: Player_ID (n... | [
"What",
"are",
"the",
"names",
"of",
"countries",
"that",
"have",
"both",
"players",
"with",
"position",
"forward",
"and",
"players",
"with",
"position",
"defender",
"?"
] |
match_season | Return the names of countries that have players that play the Forward position, as well as players who play the Defender position. | SELECT T1.Country_name FROM country AS T1 JOIN match_season AS T2 ON T1.Country_id = T2.Country WHERE T2.Position = "Forward" INTERSECT SELECT T1.Country_name FROM country AS T1 JOIN match_season AS T2 ON T1.Country_id = T2.Country WHERE T2.Position = "Defender" | country: Country_id (number), Country_name (text), Capital (text), Official_native_language (text) | team: Team_id (number), Name (text) | match_season: Season (number), Player (text), Position (text), Country (number), Team (number), Draft_Pick_Number (number), Draft_Class (text), College (text) | player: Player_ID (n... | [
"Return",
"the",
"names",
"of",
"countries",
"that",
"have",
"players",
"that",
"play",
"the",
"Forward",
"position",
",",
"as",
"well",
"as",
"players",
"who",
"play",
"the",
"Defender",
"position",
"."
] |
match_season | Which college have both players with position midfielder and players with position defender? | SELECT College FROM match_season WHERE POSITION = "Midfielder" INTERSECT SELECT College FROM match_season WHERE POSITION = "Defender" | country: Country_id (number), Country_name (text), Capital (text), Official_native_language (text) | team: Team_id (number), Name (text) | match_season: Season (number), Player (text), Position (text), Country (number), Team (number), Draft_Pick_Number (number), Draft_Class (text), College (text) | player: Player_ID (n... | [
"Which",
"college",
"have",
"both",
"players",
"with",
"position",
"midfielder",
"and",
"players",
"with",
"position",
"defender",
"?"
] |
match_season | Return the colleges that have players who play the Midfielder position, as well as players who play the Defender position. | SELECT College FROM match_season WHERE POSITION = "Midfielder" INTERSECT SELECT College FROM match_season WHERE POSITION = "Defender" | country: Country_id (number), Country_name (text), Capital (text), Official_native_language (text) | team: Team_id (number), Name (text) | match_season: Season (number), Player (text), Position (text), Country (number), Team (number), Draft_Pick_Number (number), Draft_Class (text), College (text) | player: Player_ID (n... | [
"Return",
"the",
"colleges",
"that",
"have",
"players",
"who",
"play",
"the",
"Midfielder",
"position",
",",
"as",
"well",
"as",
"players",
"who",
"play",
"the",
"Defender",
"position",
"."
] |
climbing | How many climbers are there? | SELECT count(*) FROM climber | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"How",
"many",
"climbers",
"are",
"there",
"?"
] |
climbing | Count the number of climbers. | SELECT count(*) FROM climber | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Count",
"the",
"number",
"of",
"climbers",
"."
] |
climbing | List the names of climbers in descending order of points. | SELECT Name FROM climber ORDER BY Points DESC | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"List",
"the",
"names",
"of",
"climbers",
"in",
"descending",
"order",
"of",
"points",
"."
] |
climbing | What are the names of the climbers, ordered by points descending? | SELECT Name FROM climber ORDER BY Points DESC | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"What",
"are",
"the",
"names",
"of",
"the",
"climbers",
",",
"ordered",
"by",
"points",
"descending",
"?"
] |
climbing | List the names of climbers whose country is not Switzerland. | SELECT Name FROM climber WHERE Country != "Switzerland" | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"List",
"the",
"names",
"of",
"climbers",
"whose",
"country",
"is",
"not",
"Switzerland",
"."
] |
climbing | What are the names of climbers who are not from the country of Switzerland? | SELECT Name FROM climber WHERE Country != "Switzerland" | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"What",
"are",
"the",
"names",
"of",
"climbers",
"who",
"are",
"not",
"from",
"the",
"country",
"of",
"Switzerland",
"?"
] |
climbing | What is the maximum point for climbers whose country is United Kingdom? | SELECT max(Points) FROM climber WHERE Country = "United Kingdom" | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"What",
"is",
"the",
"maximum",
"point",
"for",
"climbers",
"whose",
"country",
"is",
"United",
"Kingdom",
"?"
] |
climbing | Return the maximum number of points for climbers from the United Kingdom. | SELECT max(Points) FROM climber WHERE Country = "United Kingdom" | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Return",
"the",
"maximum",
"number",
"of",
"points",
"for",
"climbers",
"from",
"the",
"United",
"Kingdom",
"."
] |
climbing | How many distinct countries are the climbers from? | SELECT COUNT(DISTINCT Country) FROM climber | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"How",
"many",
"distinct",
"countries",
"are",
"the",
"climbers",
"from",
"?"
] |
climbing | Count the number of different countries that climbers are from. | SELECT COUNT(DISTINCT Country) FROM climber | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Count",
"the",
"number",
"of",
"different",
"countries",
"that",
"climbers",
"are",
"from",
"."
] |
climbing | What are the names of mountains in ascending alphabetical order? | SELECT Name FROM mountain ORDER BY Name ASC | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"What",
"are",
"the",
"names",
"of",
"mountains",
"in",
"ascending",
"alphabetical",
"order",
"?"
] |
climbing | Give the names of mountains in alphabetical order. | SELECT Name FROM mountain ORDER BY Name ASC | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Give",
"the",
"names",
"of",
"mountains",
"in",
"alphabetical",
"order",
"."
] |
climbing | What are the countries of mountains with height bigger than 5000? | SELECT Country FROM mountain WHERE Height > 5000 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"What",
"are",
"the",
"countries",
"of",
"mountains",
"with",
"height",
"bigger",
"than",
"5000",
"?"
] |
climbing | Return the countries of the mountains that have a height larger than 5000. | SELECT Country FROM mountain WHERE Height > 5000 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Return",
"the",
"countries",
"of",
"the",
"mountains",
"that",
"have",
"a",
"height",
"larger",
"than",
"5000",
"."
] |
climbing | What is the name of the highest mountain? | SELECT Name FROM mountain ORDER BY Height DESC LIMIT 1 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"What",
"is",
"the",
"name",
"of",
"the",
"highest",
"mountain",
"?"
] |
climbing | Return the name of the mountain with the greatest height. | SELECT Name FROM mountain ORDER BY Height DESC LIMIT 1 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Return",
"the",
"name",
"of",
"the",
"mountain",
"with",
"the",
"greatest",
"height",
"."
] |
climbing | List the distinct ranges of the mountains with the top 3 prominence. | SELECT DISTINCT Range FROM mountain ORDER BY Prominence DESC LIMIT 3 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"List",
"the",
"distinct",
"ranges",
"of",
"the",
"mountains",
"with",
"the",
"top",
"3",
"prominence",
"."
] |
climbing | What are the different ranges of the 3 mountains with the highest prominence? | SELECT DISTINCT Range FROM mountain ORDER BY Prominence DESC LIMIT 3 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"What",
"are",
"the",
"different",
"ranges",
"of",
"the",
"3",
"mountains",
"with",
"the",
"highest",
"prominence",
"?"
] |
climbing | 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 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Show",
"names",
"of",
"climbers",
"and",
"the",
"names",
"of",
"mountains",
"they",
"climb",
"."
] |
climbing | What are the names of climbers and the corresponding names of mountains that they climb? | SELECT T1.Name , T2.Name FROM climber AS T1 JOIN mountain AS T2 ON T1.Mountain_ID = T2.Mountain_ID | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"What",
"are",
"the",
"names",
"of",
"climbers",
"and",
"the",
"corresponding",
"names",
"of",
"mountains",
"that",
"they",
"climb",
"?"
] |
climbing | 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 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Show",
"the",
"names",
"of",
"climbers",
"and",
"the",
"heights",
"of",
"mountains",
"they",
"climb",
"."
] |
climbing | What are the names of climbers and the corresponding heights of the mountains that they climb? | SELECT T1.Name , T2.Height FROM climber AS T1 JOIN mountain AS T2 ON T1.Mountain_ID = T2.Mountain_ID | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"What",
"are",
"the",
"names",
"of",
"climbers",
"and",
"the",
"corresponding",
"heights",
"of",
"the",
"mountains",
"that",
"they",
"climb",
"?"
] |
climbing | 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 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Show",
"the",
"height",
"of",
"the",
"mountain",
"climbed",
"by",
"the",
"climber",
"with",
"the",
"maximum",
"points",
"."
] |
climbing | What is the height of the mountain climbined by the climbing who had the most 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 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"What",
"is",
"the",
"height",
"of",
"the",
"mountain",
"climbined",
"by",
"the",
"climbing",
"who",
"had",
"the",
"most",
"points",
"?"
] |
climbing | 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" | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Show",
"the",
"distinct",
"names",
"of",
"mountains",
"climbed",
"by",
"climbers",
"from",
"country",
"``",
"West",
"Germany",
"''",
"."
] |
climbing | What are the different names of mountains ascended by climbers from the country of 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" | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"What",
"are",
"the",
"different",
"names",
"of",
"mountains",
"ascended",
"by",
"climbers",
"from",
"the",
"country",
"of",
"West",
"Germany",
"?"
] |
climbing | 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" | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Show",
"the",
"times",
"used",
"by",
"climbers",
"to",
"climb",
"mountains",
"in",
"Country",
"Uganda",
"."
] |
climbing | What are the times used by climbers who climbed mountains in the country of Uganda? | SELECT T1.Time FROM climber AS T1 JOIN mountain AS T2 ON T1.Mountain_ID = T2.Mountain_ID WHERE T2.Country = "Uganda" | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"What",
"are",
"the",
"times",
"used",
"by",
"climbers",
"who",
"climbed",
"mountains",
"in",
"the",
"country",
"of",
"Uganda",
"?"
] |
climbing | Please show the countries and the number of climbers from each country. | SELECT Country , COUNT(*) FROM climber GROUP BY Country | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Please",
"show",
"the",
"countries",
"and",
"the",
"number",
"of",
"climbers",
"from",
"each",
"country",
"."
] |
climbing | How many climbers are from each country? | SELECT Country , COUNT(*) FROM climber GROUP BY Country | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"How",
"many",
"climbers",
"are",
"from",
"each",
"country",
"?"
] |
climbing | List the countries that have more than one mountain. | SELECT Country FROM mountain GROUP BY Country HAVING COUNT(*) > 1 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"List",
"the",
"countries",
"that",
"have",
"more",
"than",
"one",
"mountain",
"."
] |
climbing | Which countries have more than one mountain? | SELECT Country FROM mountain GROUP BY Country HAVING COUNT(*) > 1 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Which",
"countries",
"have",
"more",
"than",
"one",
"mountain",
"?"
] |
climbing | 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) | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"List",
"the",
"names",
"of",
"mountains",
"that",
"do",
"not",
"have",
"any",
"climber",
"."
] |
climbing | What are the names of countains that no climber has climbed? | SELECT Name FROM mountain WHERE Mountain_ID NOT IN (SELECT Mountain_ID FROM climber) | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"What",
"are",
"the",
"names",
"of",
"countains",
"that",
"no",
"climber",
"has",
"climbed",
"?"
] |
climbing | 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 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Show",
"the",
"countries",
"that",
"have",
"mountains",
"with",
"height",
"more",
"than",
"5600",
"stories",
"and",
"mountains",
"with",
"height",
"less",
"than",
"5200",
"."
] |
climbing | What are the countries that have both mountains that are higher than 5600 and lower than 5200? | SELECT Country FROM mountain WHERE Height > 5600 INTERSECT SELECT Country FROM mountain WHERE Height < 5200 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"What",
"are",
"the",
"countries",
"that",
"have",
"both",
"mountains",
"that",
"are",
"higher",
"than",
"5600",
"and",
"lower",
"than",
"5200",
"?"
] |
climbing | Show the range that has the most number of mountains. | SELECT Range FROM mountain GROUP BY Range ORDER BY COUNT(*) DESC LIMIT 1 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Show",
"the",
"range",
"that",
"has",
"the",
"most",
"number",
"of",
"mountains",
"."
] |
climbing | Which range contains the most mountains? | SELECT Range FROM mountain GROUP BY Range ORDER BY COUNT(*) DESC LIMIT 1 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Which",
"range",
"contains",
"the",
"most",
"mountains",
"?"
] |
climbing | Show the names of mountains with height more than 5000 or prominence more than 1000. | SELECT Name FROM mountain WHERE Height > 5000 OR Prominence > 1000 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"Show",
"the",
"names",
"of",
"mountains",
"with",
"height",
"more",
"than",
"5000",
"or",
"prominence",
"more",
"than",
"1000",
"."
] |
climbing | What are the names of mountains that have a height of over 5000 or a prominence of over 1000? | SELECT Name FROM mountain WHERE Height > 5000 OR Prominence > 1000 | mountain: Mountain_ID (number), Name (text), Height (number), Prominence (number), Range (text), Country (text) | climber: Climber_ID (number), Name (text), Country (text), Time (text), Points (number), Mountain_ID (number) | [
"What",
"are",
"the",
"names",
"of",
"mountains",
"that",
"have",
"a",
"height",
"of",
"over",
"5000",
"or",
"a",
"prominence",
"of",
"over",
"1000",
"?"
] |
body_builder | How many body builders are there? | SELECT count(*) FROM body_builder | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"How",
"many",
"body",
"builders",
"are",
"there",
"?"
] |
body_builder | List the total scores of body builders in ascending order. | SELECT Total FROM body_builder ORDER BY Total ASC | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"List",
"the",
"total",
"scores",
"of",
"body",
"builders",
"in",
"ascending",
"order",
"."
] |
body_builder | List the snatch score and clean jerk score of body builders in ascending order of snatch score. | SELECT Snatch , Clean_Jerk FROM body_builder ORDER BY Snatch ASC | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"List",
"the",
"snatch",
"score",
"and",
"clean",
"jerk",
"score",
"of",
"body",
"builders",
"in",
"ascending",
"order",
"of",
"snatch",
"score",
"."
] |
body_builder | What is the average snatch score of body builders? | SELECT avg(Snatch) FROM body_builder | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"What",
"is",
"the",
"average",
"snatch",
"score",
"of",
"body",
"builders",
"?"
] |
body_builder | What are the clean and jerk score of the body builder with the highest total score? | SELECT Clean_Jerk FROM body_builder ORDER BY Total DESC LIMIT 1 | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"What",
"are",
"the",
"clean",
"and",
"jerk",
"score",
"of",
"the",
"body",
"builder",
"with",
"the",
"highest",
"total",
"score",
"?"
] |
body_builder | What are the birthdays of people in ascending order of height? | SELECT Birth_Date FROM People ORDER BY Height ASC | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"What",
"are",
"the",
"birthdays",
"of",
"people",
"in",
"ascending",
"order",
"of",
"height",
"?"
] |
body_builder | What are the names of body builders? | SELECT T2.Name FROM body_builder AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"What",
"are",
"the",
"names",
"of",
"body",
"builders",
"?"
] |
body_builder | What are the names of body builders whose total score is higher than 300? | SELECT T2.Name FROM body_builder AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Total > 300 | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"What",
"are",
"the",
"names",
"of",
"body",
"builders",
"whose",
"total",
"score",
"is",
"higher",
"than",
"300",
"?"
] |
body_builder | What is the name of the body builder with the greatest body weight? | SELECT T2.Name FROM body_builder AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Weight DESC LIMIT 1 | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"What",
"is",
"the",
"name",
"of",
"the",
"body",
"builder",
"with",
"the",
"greatest",
"body",
"weight",
"?"
] |
body_builder | What are the birth date and birth place of the body builder with the highest total points? | SELECT T2.Birth_Date , T2.Birth_Place FROM body_builder AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Total DESC LIMIT 1 | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"What",
"are",
"the",
"birth",
"date",
"and",
"birth",
"place",
"of",
"the",
"body",
"builder",
"with",
"the",
"highest",
"total",
"points",
"?"
] |
body_builder | What are the heights of body builders with total score smaller than 315? | SELECT T2.Height FROM body_builder AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Total < 315 | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"What",
"are",
"the",
"heights",
"of",
"body",
"builders",
"with",
"total",
"score",
"smaller",
"than",
"315",
"?"
] |
body_builder | What is the average total score of body builders with height bigger than 200? | SELECT avg(T1.Total) FROM body_builder AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200 | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"What",
"is",
"the",
"average",
"total",
"score",
"of",
"body",
"builders",
"with",
"height",
"bigger",
"than",
"200",
"?"
] |
body_builder | What are the names of body builders in descending order of total scores? | SELECT T2.Name FROM body_builder AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Total DESC | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"What",
"are",
"the",
"names",
"of",
"body",
"builders",
"in",
"descending",
"order",
"of",
"total",
"scores",
"?"
] |
body_builder | List each birth place along with the number of people from there. | SELECT Birth_Place , COUNT(*) FROM people GROUP BY Birth_Place | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"List",
"each",
"birth",
"place",
"along",
"with",
"the",
"number",
"of",
"people",
"from",
"there",
"."
] |
body_builder | What is the most common birth place of people? | SELECT Birth_Place FROM people GROUP BY Birth_Place ORDER BY COUNT(*) DESC LIMIT 1 | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"What",
"is",
"the",
"most",
"common",
"birth",
"place",
"of",
"people",
"?"
] |
body_builder | What are the birth places that are shared by at least two people? | SELECT Birth_Place FROM people GROUP BY Birth_Place HAVING COUNT(*) >= 2 | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"What",
"are",
"the",
"birth",
"places",
"that",
"are",
"shared",
"by",
"at",
"least",
"two",
"people",
"?"
] |
body_builder | List the height and weight of people in descending order of height. | SELECT Height , Weight FROM people ORDER BY Height DESC | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"List",
"the",
"height",
"and",
"weight",
"of",
"people",
"in",
"descending",
"order",
"of",
"height",
"."
] |
body_builder | Show all information about each body builder. | SELECT * FROM body_builder | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"Show",
"all",
"information",
"about",
"each",
"body",
"builder",
"."
] |
body_builder | List the names and origins of people who are not body builders. | SELECT Name , birth_place FROM people EXCEPT SELECT T1.Name , T1.birth_place FROM people AS T1 JOIN body_builder AS T2 ON T1.people_id = T2.people_id | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"List",
"the",
"names",
"and",
"origins",
"of",
"people",
"who",
"are",
"not",
"body",
"builders",
"."
] |
body_builder | How many distinct birth places are there? | SELECT count(DISTINCT Birth_Place) FROM people | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"How",
"many",
"distinct",
"birth",
"places",
"are",
"there",
"?"
] |
body_builder | How many persons are not body builders? | SELECT count(*) FROM people WHERE people_id NOT IN (SELECT People_ID FROM body_builder) | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"How",
"many",
"persons",
"are",
"not",
"body",
"builders",
"?"
] |
body_builder | List the weight of the body builders who have snatch score higher than 140 or have the height greater than 200. | SELECT T2.weight FROM body_builder AS T1 JOIN people AS T2 ON T1.people_id = T2.people_id WHERE T1.snatch > 140 OR T2.height > 200; | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"List",
"the",
"weight",
"of",
"the",
"body",
"builders",
"who",
"have",
"snatch",
"score",
"higher",
"than",
"140",
"or",
"have",
"the",
"height",
"greater",
"than",
"200",
"."
] |
body_builder | What are the total scores of the body builders whose birthday contains the string "January" ? | SELECT T1.total FROM body_builder AS T1 JOIN people AS T2 ON T1.people_id = T2.people_id WHERE T2.Birth_Date LIKE "%January%"; | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"What",
"are",
"the",
"total",
"scores",
"of",
"the",
"body",
"builders",
"whose",
"birthday",
"contains",
"the",
"string",
"``",
"January",
"''",
"?"
] |
body_builder | What is the minimum snatch score? | SELECT min(snatch) FROM body_builder | body_builder: Body_Builder_ID (number), People_ID (number), Snatch (number), Clean_Jerk (number), Total (number) | people: People_ID (number), Name (text), Height (number), Weight (number), Birth_Date (text), Birth_Place (text) | [
"What",
"is",
"the",
"minimum",
"snatch",
"score",
"?"
] |
election_representative | How many elections are there? | SELECT count(*) FROM election | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"How",
"many",
"elections",
"are",
"there",
"?"
] |
election_representative | List the votes of elections in descending order. | SELECT Votes FROM election ORDER BY Votes DESC | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"List",
"the",
"votes",
"of",
"elections",
"in",
"descending",
"order",
"."
] |
election_representative | List the dates and vote percents of elections. | SELECT Date , Vote_Percent FROM election | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"List",
"the",
"dates",
"and",
"vote",
"percents",
"of",
"elections",
"."
] |
election_representative | What are the minimum and maximum vote percents of elections? | SELECT min(Vote_Percent) , max(Vote_Percent) FROM election | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"What",
"are",
"the",
"minimum",
"and",
"maximum",
"vote",
"percents",
"of",
"elections",
"?"
] |
election_representative | What are the names and parties of representatives? | SELECT Name , Party FROM representative | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"What",
"are",
"the",
"names",
"and",
"parties",
"of",
"representatives",
"?"
] |
election_representative | What are the names of representatives whose party is not "Republican"? | SELECT Name FROM Representative WHERE Party != "Republican" | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"What",
"are",
"the",
"names",
"of",
"representatives",
"whose",
"party",
"is",
"not",
"``",
"Republican",
"''",
"?"
] |
election_representative | What are the life spans of representatives from New York state or Indiana state? | SELECT Lifespan FROM representative WHERE State = "New York" OR State = "Indiana" | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"What",
"are",
"the",
"life",
"spans",
"of",
"representatives",
"from",
"New",
"York",
"state",
"or",
"Indiana",
"state",
"?"
] |
election_representative | What are the names of representatives and the dates of elections they participated in. | SELECT T2.Name , T1.Date FROM election AS T1 JOIN representative AS T2 ON T1.Representative_ID = T2.Representative_ID | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"What",
"are",
"the",
"names",
"of",
"representatives",
"and",
"the",
"dates",
"of",
"elections",
"they",
"participated",
"in",
"."
] |
election_representative | What are the names of representatives with more than 10000 votes in election? | SELECT T2.Name FROM election AS T1 JOIN representative AS T2 ON T1.Representative_ID = T2.Representative_ID WHERE Votes > 10000 | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"What",
"are",
"the",
"names",
"of",
"representatives",
"with",
"more",
"than",
"10000",
"votes",
"in",
"election",
"?"
] |
election_representative | What are the names of representatives in descending order of votes? | SELECT T2.Name FROM election AS T1 JOIN representative AS T2 ON T1.Representative_ID = T2.Representative_ID ORDER BY votes DESC | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"What",
"are",
"the",
"names",
"of",
"representatives",
"in",
"descending",
"order",
"of",
"votes",
"?"
] |
election_representative | What is the party of the representative that has the smallest number of votes. | SELECT T2.Party FROM election AS T1 JOIN representative AS T2 ON T1.Representative_ID = T2.Representative_ID ORDER BY votes ASC LIMIT 1 | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"What",
"is",
"the",
"party",
"of",
"the",
"representative",
"that",
"has",
"the",
"smallest",
"number",
"of",
"votes",
"."
] |
election_representative | What are the lifespans of representatives in descending order of vote percent? | SELECT T2.Lifespan FROM election AS T1 JOIN representative AS T2 ON T1.Representative_ID = T2.Representative_ID ORDER BY Vote_Percent DESC | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"What",
"are",
"the",
"lifespans",
"of",
"representatives",
"in",
"descending",
"order",
"of",
"vote",
"percent",
"?"
] |
election_representative | What is the average number of votes of representatives from party "Republican"? | SELECT avg(T1.Votes) FROM election AS T1 JOIN representative AS T2 ON T1.Representative_ID = T2.Representative_ID WHERE T2.Party = "Republican" | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"What",
"is",
"the",
"average",
"number",
"of",
"votes",
"of",
"representatives",
"from",
"party",
"``",
"Republican",
"''",
"?"
] |
election_representative | What are the different parties of representative? Show the party name and the number of representatives in each party. | SELECT Party , COUNT(*) FROM representative GROUP BY Party | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"What",
"are",
"the",
"different",
"parties",
"of",
"representative",
"?",
"Show",
"the",
"party",
"name",
"and",
"the",
"number",
"of",
"representatives",
"in",
"each",
"party",
"."
] |
election_representative | What is the party that has the largest number of representatives? | SELECT Party , COUNT(*) FROM representative GROUP BY Party ORDER BY COUNT(*) DESC LIMIT 1 | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"What",
"is",
"the",
"party",
"that",
"has",
"the",
"largest",
"number",
"of",
"representatives",
"?"
] |
election_representative | What parties have at least three representatives? | SELECT Party FROM representative GROUP BY Party HAVING COUNT(*) >= 3 | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"What",
"parties",
"have",
"at",
"least",
"three",
"representatives",
"?"
] |
election_representative | What states have at least two representatives? | SELECT State FROM representative GROUP BY State HAVING COUNT(*) >= 2 | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"What",
"states",
"have",
"at",
"least",
"two",
"representatives",
"?"
] |
election_representative | List the names of representatives that have not participated in elections listed here. | SELECT Name FROM representative WHERE Representative_ID NOT IN (SELECT Representative_ID FROM election) | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"List",
"the",
"names",
"of",
"representatives",
"that",
"have",
"not",
"participated",
"in",
"elections",
"listed",
"here",
"."
] |
election_representative | Show the parties that have both representatives in New York state and representatives in Pennsylvania state. | SELECT Party FROM representative WHERE State = "New York" INTERSECT SELECT Party FROM representative WHERE State = "Pennsylvania" | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"Show",
"the",
"parties",
"that",
"have",
"both",
"representatives",
"in",
"New",
"York",
"state",
"and",
"representatives",
"in",
"Pennsylvania",
"state",
"."
] |
election_representative | How many distinct parties are there for representatives? | SELECT count(DISTINCT Party) FROM representative | election: Election_ID (number), Representative_ID (number), Date (text), Votes (number), Vote_Percent (number), Seats (number), Place (number) | representative: Representative_ID (number), Name (text), State (text), Party (text), Lifespan (text) | [
"How",
"many",
"distinct",
"parties",
"are",
"there",
"for",
"representatives",
"?"
] |
apartment_rentals | How many apartment bookings are there in total? | SELECT count(*) FROM Apartment_Bookings | Apartment_Buildings: building_id (number), building_short_name (text), building_full_name (text), building_description (text), building_address (text), building_manager (text), building_phone (text) | Apartments: apt_id (number), building_id (number), apt_type_code (text), apt_number (text), bathroom_count (number), be... | [
"How",
"many",
"apartment",
"bookings",
"are",
"there",
"in",
"total",
"?"
] |
apartment_rentals | Count the total number of apartment bookings. | SELECT count(*) FROM Apartment_Bookings | Apartment_Buildings: building_id (number), building_short_name (text), building_full_name (text), building_description (text), building_address (text), building_manager (text), building_phone (text) | Apartments: apt_id (number), building_id (number), apt_type_code (text), apt_number (text), bathroom_count (number), be... | [
"Count",
"the",
"total",
"number",
"of",
"apartment",
"bookings",
"."
] |
apartment_rentals | Show the start dates and end dates of all the apartment bookings. | SELECT booking_start_date , booking_end_date FROM Apartment_Bookings | Apartment_Buildings: building_id (number), building_short_name (text), building_full_name (text), building_description (text), building_address (text), building_manager (text), building_phone (text) | Apartments: apt_id (number), building_id (number), apt_type_code (text), apt_number (text), bathroom_count (number), be... | [
"Show",
"the",
"start",
"dates",
"and",
"end",
"dates",
"of",
"all",
"the",
"apartment",
"bookings",
"."
] |
apartment_rentals | What are the start date and end date of each apartment booking? | SELECT booking_start_date , booking_end_date FROM Apartment_Bookings | Apartment_Buildings: building_id (number), building_short_name (text), building_full_name (text), building_description (text), building_address (text), building_manager (text), building_phone (text) | Apartments: apt_id (number), building_id (number), apt_type_code (text), apt_number (text), bathroom_count (number), be... | [
"What",
"are",
"the",
"start",
"date",
"and",
"end",
"date",
"of",
"each",
"apartment",
"booking",
"?"
] |
apartment_rentals | Show all distinct building descriptions. | SELECT DISTINCT building_description FROM Apartment_Buildings | Apartment_Buildings: building_id (number), building_short_name (text), building_full_name (text), building_description (text), building_address (text), building_manager (text), building_phone (text) | Apartments: apt_id (number), building_id (number), apt_type_code (text), apt_number (text), bathroom_count (number), be... | [
"Show",
"all",
"distinct",
"building",
"descriptions",
"."
] |
apartment_rentals | Give me a list of all the distinct building descriptions. | SELECT DISTINCT building_description FROM Apartment_Buildings | Apartment_Buildings: building_id (number), building_short_name (text), building_full_name (text), building_description (text), building_address (text), building_manager (text), building_phone (text) | Apartments: apt_id (number), building_id (number), apt_type_code (text), apt_number (text), bathroom_count (number), be... | [
"Give",
"me",
"a",
"list",
"of",
"all",
"the",
"distinct",
"building",
"descriptions",
"."
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.