output
stringlengths
27
479
instruction
stringlengths
407
1.39k
SELECT MIN("year") FROM "recent_government_budget_balances" WHERE "expenditure"=55 AND "income"<36.2;
## Task Generate a SQL query to answer the following question: `Which Year has an Expenditure of 55, and an Income smaller than 36.2?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "recent_government_budget_balances" ( "year" real, "income" real, ...
SELECT "pct_gdp" FROM "recent_government_budget_balances" WHERE "year"<2011 AND "expenditure">41.3 AND "income"<48 AND "surplus_deficit"='(24.6)';
## Task Generate a SQL query to answer the following question: `Which % GDP has a Year smaller than 2011, and an Expenditure larger than 41.3, and an Income smaller than 48, and a Surplus(Deficit) of (24.6)?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TAB...
SELECT "year" FROM "singles" WHERE "tournament_name"='grand prix passing shot bordeaux' AND "runners_up"='diego nargiso';
## Task Generate a SQL query to answer the following question: `What year was the Grand Prix Passing Shot Bordeaux that had Runners-up of Diego Nargiso?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "singles" ( "year" real, "tournament_name" text,...
SELECT "tournament_name" FROM "singles" WHERE "score"='5–7, 6–4, 6–4';
## Task Generate a SQL query to answer the following question: `What tournament had a score of 5–7, 6–4, 6–4?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "singles" ( "year" real, "tournament_name" text, "champions" text, "runners_up" text, ...
SELECT "score" FROM "singles" WHERE "year">1989 AND "tournament_name"='grand prix passing shot' AND "runners_up"='jeff tarango';
## Task Generate a SQL query to answer the following question: `After 1989, what was the score of the Grand Prix Passing Shot where the Runners-up were Jeff Tarango?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "singles" ( "year" real, "tournamen...
SELECT "tournament_name" FROM "singles" WHERE "runners_up"='gianni ocleppo';
## Task Generate a SQL query to answer the following question: `What's the name of the tournament that Gianni Ocleppo was the runner-up?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "singles" ( "year" real, "tournament_name" text, "champions" t...
SELECT MIN("winpct") FROM "regular_season_results" WHERE "games_behind"='6½' AND "wins">77;
## Task Generate a SQL query to answer the following question: `What is the lowest percentage of wins for 6½ games and more than 77 total wins?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "regular_season_results" ( "season" text, "wins" real, ...
SELECT "score" FROM "november" WHERE "date"='november 10';
## Task Generate a SQL query to answer the following question: `What is the score of the competition on November 10?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "november" ( "date" text, "visitor" text, "score" text, "home" text, "leading_...
SELECT "visitor" FROM "november" WHERE "record"='2-1';
## Task Generate a SQL query to answer the following question: `Who is the visitor when the record is 2-1?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "november" ( "date" text, "visitor" text, "score" text, "home" text, "leading_scorer" te...
SELECT "home" FROM "november" WHERE "score"='81-80';
## Task Generate a SQL query to answer the following question: `Who is the home team when the score is 81-80?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "november" ( "date" text, "visitor" text, "score" text, "home" text, "leading_scorer"...
SELECT SUM("gold") FROM "medal_table_unofficial" WHERE "nation"='japan' AND "total">1;
## Task Generate a SQL query to answer the following question: `How many Gold medals did Japan receive who had a Total of more than 1 medals?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "medal_table_unofficial" ( "rank" text, "nation" text, "g...
SELECT "time_cst" FROM "schedule" WHERE "nfl_recap"='recap' AND "date"='october 19, 2008';
## Task Generate a SQL query to answer the following question: `What time (cst) has and NFL recap of recap with october 19, 2008 as the date?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "schedule" ( "week" real, "date" text, "time_cst" text, ...
SELECT "week" FROM "schedule" WHERE "game_site"='giants stadium';
## Task Generate a SQL query to answer the following question: `Which week has giants stadium as the game site?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "schedule" ( "week" real, "date" text, "time_cst" text, "opponent" text, "result" t...
SELECT MIN("week") FROM "schedule" WHERE "time_cst"='7:15 p.m.' AND "game_site"='fedexfield';
## Task Generate a SQL query to answer the following question: `What is the lowest week that has 7:15 p.m. as the time (cst) and fedexfield as the game site?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "schedule" ( "week" real, "date" text, "t...
SELECT "office" FROM "1934_state_election_results" WHERE "law_preservation_ticket"='william e. barron';
## Task Generate a SQL query to answer the following question: `What office was law preservation ticket holder William E. Barron running for?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1934_state_election_results" ( "office" text, "democratic_...
SELECT "constitutional_ticket" FROM "1934_state_election_results" WHERE "republican_ticket"='charles b. sears';
## Task Generate a SQL query to answer the following question: `Who was the constitutional ticken when Charles B. Sears was the republican ticket?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1934_state_election_results" ( "office" text, "democr...
SELECT "constitutional_ticket" FROM "1934_state_election_results" WHERE "socialist_ticket"='william karlin';
## Task Generate a SQL query to answer the following question: `Who was the constitutional ticket when william karlin was the socialist ticket?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "1934_state_election_results" ( "office" text, "democrati...
SELECT "margin_of_victory" FROM "pga_tour_wins_10" WHERE "date"='mar 18, 1979';
## Task Generate a SQL query to answer the following question: `What was the margin of victory on Mar 18, 1979?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "pga_tour_wins_10" ( "date" text, "tournament" text, "winning_score" text, "margin_of...
SELECT "comp" FROM "regular_season" WHERE "year"='1989';
## Task Generate a SQL query to answer the following question: `What is the comp for the year 1989?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "regular_season" ( "year" text, "team" text, "comp" text, "rate" text, "r_att" text, "r_yds" ...
SELECT "team" FROM "regular_season" WHERE "year"='1989';
## Task Generate a SQL query to answer the following question: `What is the team in 1989?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "regular_season" ( "year" text, "team" text, "comp" text, "rate" text, "r_att" text, "r_yds" text, "r...
SELECT "r_att" FROM "regular_season" WHERE "year"='1988';
## Task Generate a SQL query to answer the following question: `What is the RAtt in the year 1988?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "regular_season" ( "year" text, "team" text, "comp" text, "rate" text, "r_att" text, "r_yds" t...
SELECT "team" FROM "regular_season" WHERE "r_att"='42';
## Task Generate a SQL query to answer the following question: `What was the team with a Ratt of 42?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "regular_season" ( "year" text, "team" text, "comp" text, "rate" text, "r_att" text, "r_yds"...
SELECT "team" FROM "regular_season" WHERE "r_att"='57';
## Task Generate a SQL query to answer the following question: `What was the team with a ratt of 57?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "regular_season" ( "year" text, "team" text, "comp" text, "rate" text, "r_att" text, "r_yds"...
SELECT "opponent" FROM "schedule" WHERE "week"<7 AND "game_site"='tulane stadium';
## Task Generate a SQL query to answer the following question: `Who did the Giants play before week 7 in Tulane Stadium?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "ga...
SELECT MIN("attendance") FROM "schedule" WHERE "week"=1;
## Task Generate a SQL query to answer the following question: `What was the lowest attendance for week 1?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "game_site" text,...
SELECT MAX("rank") FROM "list_of_top_association_football_goal_sc" WHERE "country"='ethiopia';
## Task Generate a SQL query to answer the following question: `What is the highest rank of a player from Ethiopia?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "list_of_top_association_football_goal_sc" ( "rank" real, "player" text, "country" ...
SELECT SUM("rank") FROM "list_of_top_association_football_goal_sc" WHERE "matches"=367 AND "goals">216;
## Task Generate a SQL query to answer the following question: `How many ranks had 367 matches and more than 216 goals?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "list_of_top_association_football_goal_sc" ( "rank" real, "name" text, "years" ...
SELECT AVG("rank") FROM "list_of_top_association_football_goal_sc" WHERE "goals"=230 AND "matches">535;
## Task Generate a SQL query to answer the following question: `What is the mean rank number when goals are 230 and there are more than 535?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "list_of_top_association_football_goal_sc" ( "rank" real, "n...
SELECT "original_airing" FROM "viewing_figures" WHERE "audience_share_average"='8%';
## Task Generate a SQL query to answer the following question: `Where the audience share is 8%, what is the original airing?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "viewing_figures" ( "episode_number" real, "season" text, "original_airing...
SELECT "season_viewer_average" FROM "viewing_figures" WHERE "episode_number"=2;
## Task Generate a SQL query to answer the following question: `For episode number 2 what is the season viewer average?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "viewing_figures" ( "episode_number" real, "season" text, "original_airing" tex...
SELECT COUNT("episode_number") FROM "viewing_figures" WHERE "audience_share_average"='10%';
## Task Generate a SQL query to answer the following question: `What episode number has an audience share of 10%?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "viewing_figures" ( "episode_number" real, "season" text, "original_airing" text, "...
SELECT "class" FROM "peter_drummond_1911_1918" WHERE "wheels"=137;
## Task Generate a SQL query to answer the following question: `What is the value for the item "Class" when the value of the item "Wheels" is 137?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "peter_drummond_1911_1918" ( "class" text, "wheels" re...
SELECT MIN("games") FROM "rebounds" WHERE "team"='fenerbahçe';
## Task Generate a SQL query to answer the following question: `What's the smallest number of games for the fenerbahçe team?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "rebounds" ( "rank" real, "name" text, "team" text, "games" real, "reb...
SELECT AVG("games") FROM "rebounds" WHERE "team"='olympiacos' AND "rebounds"<17;
## Task Generate a SQL query to answer the following question: `What's the mean game number for the olympiacos team when there's less than 17 rebounds?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "rebounds" ( "rank" real, "name" text, "team" t...
SELECT COUNT("games") FROM "rebounds" WHERE "name"='novica veličković' AND "rebounds">24;
## Task Generate a SQL query to answer the following question: `How many games does novica veličković have when there's more than 24 rebounds?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "rebounds" ( "rank" real, "name" text, "team" text, "g...
SELECT "league" FROM "year_by_year_record" WHERE "year"='1990/91';
## Task Generate a SQL query to answer the following question: `What is the League with a Year that is 1990/91?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "year_by_year_record" ( "year" text, "league" text, "reg_season" text, "playoffs" tex...
SELECT "icao" FROM "destinations" WHERE "airport"='simferopol international airport';
## Task Generate a SQL query to answer the following question: `What is the ICAO for simferopol international airport?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "destinations" ( "city" text, "country" text, "iata" text, "icao" text, "air...
SELECT "country" FROM "destinations" WHERE "iata"='gzt';
## Task Generate a SQL query to answer the following question: `Which country has an IATA of gzt?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "destinations" ( "city" text, "country" text, "iata" text, "icao" text, "airport" text ); ### SQL...
SELECT "country" FROM "destinations" WHERE "city"='yerevan';
## Task Generate a SQL query to answer the following question: `What country is Yerevan located in?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "destinations" ( "city" text, "country" text, "iata" text, "icao" text, "airport" text ); ### S...
SELECT "icao" FROM "destinations" WHERE "iata"='ika';
## Task Generate a SQL query to answer the following question: `What is the ICAO when the IATA is ika?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "destinations" ( "city" text, "country" text, "iata" text, "icao" text, "airport" text ); ##...
SELECT "icao" FROM "destinations" WHERE "iata"='ist';
## Task Generate a SQL query to answer the following question: `What is the ICAO when the IATA is ist?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "destinations" ( "city" text, "country" text, "iata" text, "icao" text, "airport" text ); ##...
SELECT "team" FROM "first_league" WHERE "lost"=10;
## Task Generate a SQL query to answer the following question: `Which team has 10 losses?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "first_league" ( "team" text, "match" real, "points" real, "draw" real, "lost" real ); ### SQL Given the ...
SELECT "annual_change" FROM "brazil_s_15_busiest_airports_by_passenge" WHERE "rank"<3 AND "capacity_in_use"='78.4%';
## Task Generate a SQL query to answer the following question: `In which yearly change was there a capacity of 78.4% and a rank smaller than 3?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "brazil_s_15_busiest_airports_by_passenge" ( "rank" real, ...
SELECT "rank" FROM "brazil_s_15_busiest_airports_by_passenge" WHERE "location"='porto alegre';
## Task Generate a SQL query to answer the following question: `In Which rank was there a location of porto alegre?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "brazil_s_15_busiest_airports_by_passenge" ( "rank" real, "location" text, "total_p...
SELECT SUM("total_passengers") FROM "brazil_s_15_busiest_airports_by_passenge" WHERE "capacity_in_use"='81.2%';
## Task Generate a SQL query to answer the following question: `what is the number of passengers when the capacity is 81.2%?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "brazil_s_15_busiest_airports_by_passenge" ( "rank" real, "location" text, ...
SELECT MAX("total_passengers") FROM "brazil_s_15_busiest_airports_by_passenge" WHERE "rank"=1;
## Task Generate a SQL query to answer the following question: `what is the highest amount of passengers when there is a rank of 1?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "brazil_s_15_busiest_airports_by_passenge" ( "rank" real, "location" ...
SELECT MAX("rank") FROM "brazil_s_15_busiest_airports_by_passenge" WHERE "annual_change"='10.3%' AND "total_passengers"<'1,368,968';
## Task Generate a SQL query to answer the following question: `Which highest rank had an annual change of 10.3% and a capacity of people smaller than 1,368,968?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "brazil_s_15_busiest_airports_by_passenge" ...
SELECT MAX("week") FROM "season_schedule" WHERE "result"='l 17–0';
## Task Generate a SQL query to answer the following question: `What was the latest Week on which the Result was l 17–0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "season_schedule" ( "week" real, "date" text, "opponent" text, "result" text...
SELECT AVG("cuts_made") FROM "summary" WHERE "top_25"<10 AND "top_10">3;
## Task Generate a SQL query to answer the following question: `What is the average cuts made at the top 25, less than 10, and at the Top 10 more than 3?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "summary" ( "tournament" text, "wins" real, "...
SELECT AVG("top_10") FROM "summary" WHERE "wins"<0;
## Task Generate a SQL query to answer the following question: `What is average Top 10 with 0 wins?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "summary" ( "tournament" text, "wins" real, "top_5" real, "top_10" real, "top_25" real, "even...
SELECT AVG("events") FROM "summary" WHERE "tournament"='the open championship' AND "top_5"<1;
## Task Generate a SQL query to answer the following question: `What is the average event for the Open Championship Tournament, and a Top-5 less than 1?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "summary" ( "tournament" text, "wins" real, "t...
SELECT AVG("wins") FROM "summary" WHERE "top_25"<0;
## Task Generate a SQL query to answer the following question: `What is the average wins has Top-25 less than 0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "summary" ( "tournament" text, "wins" real, "top_5" real, "top_10" real, "top_25" ...
SELECT MAX("against") FROM "2012_ladder" WHERE "byes">0;
## Task Generate a SQL query to answer the following question: `What is the largest Against with a Byes larger than 0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2012_ladder" ( "peel" text, "wins" real, "byes" real, "losses" real, "draws...
SELECT MAX("wins") FROM "2012_ladder" WHERE "against"=1940 AND "byes">0;
## Task Generate a SQL query to answer the following question: `Which Wins has an Against of 1940, and a Byes larger than 0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2012_ladder" ( "peel" text, "wins" real, "byes" real, "losses" real, ...
SELECT AVG("draws") FROM "2012_ladder" WHERE "wins"=10 AND "peel"='south mandurah' AND "byes">0;
## Task Generate a SQL query to answer the following question: `Which Draws has a Wins of 10, and a Peel of south mandurah, and a Byes larger than 0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2012_ladder" ( "peel" text, "wins" real, "byes" ...
SELECT MAX("against") FROM "2012_ladder" WHERE "draws">0 AND "losses"<16 AND "wins"<4;
## Task Generate a SQL query to answer the following question: `Which Against has a Draws larger than 0, a Losses smaller than 16, and a Wins smaller than 4?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2012_ladder" ( "peel" text, "wins" real, ...
SELECT COUNT("losses") FROM "2012_ladder" WHERE "against"=1101 AND "byes"<0;
## Task Generate a SQL query to answer the following question: `Which Losses has an Against of 1101, and a Byes smaller than 0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2012_ladder" ( "peel" text, "wins" real, "byes" real, "losses" real,...
SELECT MAX("byes") FROM "2012_ladder" WHERE "losses"<1;
## Task Generate a SQL query to answer the following question: `Which Byes has a Losses smaller than 1?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2012_ladder" ( "peel" text, "wins" real, "byes" real, "losses" real, "draws" real, "agai...
SELECT AVG("games") FROM "points" WHERE "rank"<1;
## Task Generate a SQL query to answer the following question: `What is the average number of games of the player with a rank less than 1?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "points" ( "rank" real, "name" text, "team" text, "games" ...
SELECT MAX("rank") FROM "points" WHERE "points"<32;
## Task Generate a SQL query to answer the following question: `What is the highest rank of the player with less than 32 points?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "points" ( "rank" real, "name" text, "team" text, "games" real, "p...
SELECT SUM("rank") FROM "points" WHERE "points"<34;
## Task Generate a SQL query to answer the following question: `What is the rank of the player with less than 34 points?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "points" ( "rank" real, "name" text, "team" text, "games" real, "points" r...
SELECT "fourth_district" FROM "current_members" WHERE "second_district"='bob springstead';
## Task Generate a SQL query to answer the following question: `Who's Fourth District has a Second District of bob springstead?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "current_members" ( "first_district" text, "second_district" text, "thi...
SELECT "first_district" FROM "current_members" WHERE "fifth_district"='prudy adam';
## Task Generate a SQL query to answer the following question: `Who's the First District with a Fifth District of prudy adam?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "current_members" ( "first_district" text, "second_district" text, "third...
SELECT "fourth_district" FROM "current_members" WHERE "first_district"='beverly bodem';
## Task Generate a SQL query to answer the following question: `Who's the Fourth District with a First District of beverly bodem?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "current_members" ( "first_district" text, "second_district" text, "t...
SELECT "fourth_district" FROM "current_members" WHERE "second_district"='kurt van koevering';
## Task Generate a SQL query to answer the following question: `Who's the Fourth District with a Second District of kurt van koevering?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "current_members" ( "first_district" text, "second_district" text...
SELECT "fifth_district" FROM "current_members" WHERE "second_district"='paul leidig';
## Task Generate a SQL query to answer the following question: `Who's the Fifth District with a Second District of paul leidig?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "current_members" ( "first_district" text, "second_district" text, "thi...
SELECT "fourth_district" FROM "current_members" WHERE "third_district"='sharon yentsch';
## Task Generate a SQL query to answer the following question: `Who's the Fourth District with a Third District of sharon yentsch?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "current_members" ( "first_district" text, "second_district" text, "...
SELECT COUNT("sets") FROM "men" WHERE "player"='gary muller';
## Task Generate a SQL query to answer the following question: `How many Sets did Gary Muller have?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "men" ( "aces" real, "player" text, "opponent" text, "event" text, "sets" real ); ### SQL Given...
SELECT "player" FROM "men" WHERE "sets"<5 AND "event"='2005 wimbledon';
## Task Generate a SQL query to answer the following question: `What Player in 2005 Wimbledon had less than 5 Sets?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "men" ( "aces" real, "player" text, "opponent" text, "event" text, "sets" real ...
SELECT "opponent" FROM "men" WHERE "aces"<50 AND "event"='2001 davis cup';
## Task Generate a SQL query to answer the following question: `At the 2001 Davis Cup, what Opponent had less than 50 Aces?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "men" ( "aces" real, "player" text, "opponent" text, "event" text, "set...
SELECT "position_in_channel_4_and_channel_4_1_s_ratings" FROM "united_kingdom" WHERE "position_in_e4_and_e4_1_s_ratings"='780,200';
## Task Generate a SQL query to answer the following question: `What is Channel 4 and Channel 4+1's rating in E4 and E4+1 when the ratings were 780,200?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "united_kingdom" ( "episode_number" real, "title...
SELECT "time_of_airing_on_channel_4" FROM "united_kingdom" WHERE "episode_number">106 AND "title"='marry me a little';
## Task Generate a SQL query to answer the following question: `What time did Channel 4 air an episode number larger than 106 with the title of Marry Me A Little?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "united_kingdom" ( "episode_number" real...
SELECT COUNT("sunk_by_u_boat") FROM "references" WHERE "german_submarines_lost"<2 AND "sunk_by_aircraft"=56328 AND "sunk_by_mines">8269;
## Task Generate a SQL query to answer the following question: `What is the total number of sunk by U-boats with less than 2 German submarines lost, 56328 sunk by aircrafts, and more than 8269 sunk by mines?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TAB...
SELECT COUNT("sunk_by_warship_or_raider") FROM "references" WHERE "german_submarines_lost"=20 AND "sunk_by_aircraft">21616;
## Task Generate a SQL query to answer the following question: `What is the total number sunk by warship or raider with 20 German submarines lost and more than 21616 sunk by aircraft?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "references" ( "mon...
SELECT COUNT("german_submarines_lost") FROM "references" WHERE "sunk_by_mines">120958;
## Task Generate a SQL query to answer the following question: `What is the total number of German submarines lost with more than 120958 sunk by mines?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "references" ( "month_year" text, "sunk_by_u_boat...
SELECT "month_year" FROM "references" WHERE "german_submarines_lost"<5 AND "sunk_by_warship_or_raider"<6893 AND "sunk_by_aircraft"<133746 AND "sunk_by_u_boat">111263;
## Task Generate a SQL query to answer the following question: `What is the month and year less than 5 German submarines were lost, less than 6893 were sunk by warship or raider, less than 133746 were sunk by aircraft, and more than 111263 were sunk by U-boat?` ### Database Schema This query will run on a database wh...
SELECT "month_year" FROM "references" WHERE "sunk_by_aircraft"<106005 AND "sunk_by_warship_or_raider"=61857;
## Task Generate a SQL query to answer the following question: `What is the month and year less than 106005 were sunk by aircraft and 61857 were sunk by warship or raider?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "references" ( "month_year" tex...
SELECT "post_1896_provinces" FROM "provinces_of_joseon" WHERE "hanja"='全羅道';
## Task Generate a SQL query to answer the following question: `What is the post-1986 provinces with a 全羅道 Hanja?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "provinces_of_joseon" ( "rr_romaja" text, "m_r_romaja" text, "hangul" text, "hanja"...
SELECT "korean_dialect" FROM "provinces_of_joseon" WHERE "capital"='daegu';
## Task Generate a SQL query to answer the following question: `What is the Korean dialect in the daegu capital?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "provinces_of_joseon" ( "rr_romaja" text, "m_r_romaja" text, "hangul" text, "hanja" ...
SELECT "korean_dialect" FROM "provinces_of_joseon" WHERE "rr_romaja"='jeolla';
## Task Generate a SQL query to answer the following question: `What is the Korean dialect with a jeolla RR Romaja?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "provinces_of_joseon" ( "rr_romaja" text, "m_r_romaja" text, "hangul" text, "hanj...
SELECT "hanja" FROM "provinces_of_joseon" WHERE "rr_romaja"='hamgyeong';
## Task Generate a SQL query to answer the following question: `What is the Hanja for the hamgyeong RR Romaja?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "provinces_of_joseon" ( "rr_romaja" text, "m_r_romaja" text, "hangul" text, "hanja" te...
SELECT AVG("example_code_huc") FROM "united_states" WHERE "example_name"='lower snake' AND "digits"=6 AND "level"<3;
## Task Generate a SQL query to answer the following question: `What is the mean huc example code when the example name's lower snake, there are 6 digits, and less than 3 levels?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "united_states" ( "name"...
SELECT COUNT("number_of_h_us_approximate") FROM "united_states" WHERE "digits">2 AND "level"=6;
## Task Generate a SQL query to answer the following question: `What's the approximate number of HUs when there are more than 2 digits, and 6 levels?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "united_states" ( "name" text, "level" real, "dig...
SELECT COUNT("example_code_huc") FROM "united_states" WHERE "level"=1;
## Task Generate a SQL query to answer the following question: `How many HUC example codes have 1 level?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "united_states" ( "name" text, "level" real, "digits" real, "average_size_square_miles" text...
SELECT AVG("level") FROM "united_states" WHERE "example_name"='lower snake' AND "number_of_h_us_approximate"<370;
## Task Generate a SQL query to answer the following question: `What is the mean level number when the example name is lower snake and the approximate number is hus is less than 370?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "united_states" ( "n...
SELECT AVG("losses") FROM "2004_ladder" WHERE "against">1255 AND "wins"=0 AND "draws"<0;
## Task Generate a SQL query to answer the following question: `What is the losses average when the against is greater than 1255 and wins is 0 and the draws less than 0?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2004_ladder" ( "ballarat_fl" tex...
SELECT MIN("losses") FROM "2004_ladder" WHERE "wins"=5 AND "against"<1852;
## Task Generate a SQL query to answer the following question: `What is the smallest losses when the wins are 5 and the against less than 1852?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2004_ladder" ( "ballarat_fl" text, "wins" real, "byes"...
SELECT SUM("against") FROM "2004_ladder" WHERE "wins"<9 AND "losses"<16 AND "byes"=2 AND "ballarat_fl"='ballarat';
## Task Generate a SQL query to answer the following question: `What is the total against that has wins less than 9, and losses less than 16, and 2 as the byes, and Ballarat FL of ballarat?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2004_ladder" (...
SELECT MIN("losses") FROM "2004_ladder" WHERE "ballarat_fl"='lake wendouree' AND "wins"<9;
## Task Generate a SQL query to answer the following question: `What is the fewest losses that Ballarat FL of Lake Wendouree has when the wins are smaller than 9?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2004_ladder" ( "ballarat_fl" text, "w...
SELECT MIN("byes") FROM "2004_ladder" WHERE "wins"=3;
## Task Generate a SQL query to answer the following question: `What is the smallest byes when the wins are 3?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "2004_ladder" ( "ballarat_fl" text, "wins" real, "byes" real, "losses" real, "draws"...
SELECT COUNT("zone") FROM "stations" WHERE "station_users_2007_08">'243,800' AND "year_opened"='1855';
## Task Generate a SQL query to answer the following question: `Can you tell me the total number of Zone than has the Station users 2007-08 larger than 243,800, and the Year opened of 1855?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "stations" ( ...
SELECT MAX("attendance") FROM "second_round_proper" WHERE "away_team"='wrexham';
## Task Generate a SQL query to answer the following question: `What is the highest Attendance when the away team was Wrexham?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round_proper" ( "tie_no" text, "home_team" text, "score" text, ...
SELECT "away_team" FROM "second_round_proper" WHERE "home_team"='wycombe wanderers';
## Task Generate a SQL query to answer the following question: `What is the Away team when the home team was wycombe wanderers?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round_proper" ( "tie_no" text, "home_team" text, "score" text, ...
SELECT MIN("attendance") FROM "second_round_proper" WHERE "home_team"='slough town';
## Task Generate a SQL query to answer the following question: `What is the lowest Attendance when the home team was slough town?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round_proper" ( "tie_no" text, "home_team" text, "score" text...
SELECT SUM("attendance") FROM "second_round_proper" WHERE "away_team"='macclesfield town';
## Task Generate a SQL query to answer the following question: `What is the sum of Attendance when macclesfield town was the way team?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "second_round_proper" ( "tie_no" text, "home_team" text, "score"...
SELECT COUNT("spins_since_1998_source_mediabase") FROM "radio_singles" WHERE "ccm_chart"='chr' AND "peak_pos"<1;
## Task Generate a SQL query to answer the following question: `How many Spins sources have a CCM Chart of CHR with a peak position less than 1?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "radio_singles" ( "single" text, "ccm_chart" text, "de...
SELECT "ccm_chart" FROM "radio_singles" WHERE "total_wks"=18;
## Task Generate a SQL query to answer the following question: `What CCM Chart had 18 total weeks?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "radio_singles" ( "single" text, "ccm_chart" text, "debut" text, "peak_date" text, "peak_pos" re...
SELECT "opponent" FROM "schedule" WHERE "date"='december 18, 1988';
## Task Generate a SQL query to answer the following question: `What is Opponent, when Date is December 18, 1988?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "attendanc...
SELECT "attendance" FROM "schedule" WHERE "opponent"='pittsburgh steelers';
## Task Generate a SQL query to answer the following question: `What is Attendance, when Opponent is Pittsburgh Steelers?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "a...
SELECT AVG("week") FROM "schedule" WHERE "result"='l 37–34';
## Task Generate a SQL query to answer the following question: `What is the average Week, when Result is l 37–34?` ### Database Schema This query will run on a database whose schema is represented in this string: CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "attendanc...