text
stringlengths
310
1.28k
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "promotion_round" ( "position" real, "name" text, "played" real, "drawn" real, "lost" real, "points" real ); Question: What is the total number for the position that has less than 2 draws, less than 9 losses and more than 24? <|assistant|> SELECT COUNT("position") FROM "promotion_round" WHERE "drawn"<2 AND "lost"<9 AND "points">24;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "promotion_round" ( "position" real, "name" text, "played" real, "drawn" real, "lost" real, "points" real ); Question: What is the highest played with more than 0 draws, less than 3 losses, and less than 27 points? <|assistant|> SELECT MAX("played") FROM "promotion_round" WHERE "drawn">0 AND "lost"<3 AND "points"<27;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "promotion_round" ( "position" real, "name" text, "played" real, "drawn" real, "lost" real, "points" real ); Question: What is the total number played with 8 points and a position more than 6? <|assistant|> SELECT COUNT("played") FROM "promotion_round" WHERE "points"=8 AND "position">6;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "promotion_round" ( "position" real, "name" text, "played" real, "drawn" real, "lost" real, "points" real ); Question: What is the total number played with 1 drawn, and less than 7 points? <|assistant|> SELECT COUNT("played") FROM "promotion_round" WHERE "drawn"=1 AND "points"<7;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "medals_table" ( "rank" text, "nation" text, "gold" real, "silver" real, "bronze" real, "total" real ); Question: What is the most silver when bronze is more than 1 and total is more than 48? <|assistant|> SELECT MAX("silver") FROM "medals_table" WHERE "bronze">1 AND "total">48;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "medals_table" ( "rank" text, "nation" text, "gold" real, "silver" real, "bronze" real, "total" real ); Question: what is the most bronze when the total is 9? <|assistant|> SELECT MAX("bronze") FROM "medals_table" WHERE "total"=9;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "medals_table" ( "rank" text, "nation" text, "gold" real, "silver" real, "bronze" real, "total" real ); Question: what is the least bronze when the nation is soviet union and the total is less than 11? <|assistant|> SELECT MIN("bronze") FROM "medals_table" WHERE "nation"='soviet union' AND "total"<11;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "list_of_awards_and_nominations_received_" ( "year" real, "category" text, "nominee_s" text, "episode" text, "result" text ); Question: What is the category when Hy Conrad nominated in 2003? <|assistant|> SELECT "category" FROM "list_of_awards_and_nominations_received_" WHERE "nominee_s"='hy conrad' AND "year"=2003;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "rushing" ( "name" text, "gp_gs" text, "gain" real, "loss" real, "long" real, "avg_g" real ); Question: What is the long figure when gain is less than 0? <|assistant|> SELECT AVG("long") FROM "rushing" WHERE "gain"<0;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "rushing" ( "name" text, "gp_gs" text, "gain" real, "loss" real, "long" real, "avg_g" real ); Question: What is the loss when the average/gain is less than 16.7, gain is 104 and long is larger than 4? <|assistant|> SELECT AVG("loss") FROM "rushing" WHERE "avg_g"<16.7 AND "long">4 AND "gain"=104;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "quarterfinal_3" ( "rank" real, "athlete" text, "country" text, "time" text, "notes" text ); Question: What is the time for Estonia with sc/d notes? <|assistant|> SELECT "time" FROM "quarterfinal_3" WHERE "notes"='sc/d' AND "country"='estonia';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "quarterfinal_3" ( "rank" real, "athlete" text, "country" text, "time" text, "notes" text ); Question: What is the time for the rank after 5 with sc/d notes? <|assistant|> SELECT "time" FROM "quarterfinal_3" WHERE "notes"='sc/d' AND "rank">5;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "quarterfinal_3" ( "rank" real, "athlete" text, "country" text, "time" text, "notes" text ); Question: What was Law Hiu Fung's time? <|assistant|> SELECT "time" FROM "quarterfinal_3" WHERE "athlete"='law hiu fung';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "quarterfinal_3" ( "rank" real, "athlete" text, "country" text, "time" text, "notes" text ); Question: What is the time for the rank after 5 with sc/d notes? <|assistant|> SELECT "time" FROM "quarterfinal_3" WHERE "notes"='sc/d' AND "rank">5;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "quarterfinal_3" ( "rank" real, "athlete" text, "country" text, "time" text, "notes" text ); Question: What is the highest rank for a 6:52.70 time and notes of sa/b? <|assistant|> SELECT MAX("rank") FROM "quarterfinal_3" WHERE "notes"='sa/b' AND "time"='6:52.70';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "semifinal_2" ( "rank" real, "lane" real, "name" text, "nationality" text, "time" text ); Question: What is the lowest rank that has paul biedermann as the name? <|assistant|> SELECT MIN("rank") FROM "semifinal_2" WHERE "name"='paul biedermann';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "semifinal_2" ( "rank" real, "lane" real, "name" text, "nationality" text, "time" text ); Question: What nationality has 2 as the rank? <|assistant|> SELECT "nationality" FROM "semifinal_2" WHERE "rank"=2;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "semifinal_2" ( "rank" real, "lane" real, "name" text, "nationality" text, "time" text ); Question: What is the highest lane that has nimrod shapira bar-or as the name? <|assistant|> SELECT MAX("lane") FROM "semifinal_2" WHERE "name"='nimrod shapira bar-or';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "awards" ( "year" real, "award" text, "work" text, "category" text, "result" text ); Question: What is the latest year they were nominated? <|assistant|> SELECT MAX("year") FROM "awards" WHERE "result"='nominated';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "awards" ( "year" real, "award" text, "work" text, "category" text, "result" text ); Question: What is the result of the choice tv actor: drama category? <|assistant|> SELECT "result" FROM "awards" WHERE "category"='choice tv actor: drama';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "relegation_round" ( "position" real, "name" text, "played" real, "drawn" real, "lost" real, "points" real ); Question: Which Drawn has a Position smaller than 8, and a Played smaller than 14? <|assistant|> SELECT MAX("drawn") FROM "relegation_round" WHERE "position"<8 AND "played"<14;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "relegation_round" ( "position" real, "name" text, "played" real, "drawn" real, "lost" real, "points" real ); Question: Which Points have a Drawn smaller than 2, and a Lost of 12, and a Name of ev bad wörishofen? <|assistant|> SELECT MAX("points") FROM "relegation_round" WHERE "drawn"<2 AND "lost"=12 AND "name"='ev bad wörishofen';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "second_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); Question: What place did Lee Westwood finish in? <|assistant|> SELECT "place" FROM "second_round" WHERE "player"='lee westwood';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "second_round" ( "place" text, "player" text, "country" text, "score" text, "to_par" text ); Question: What is the to par score of the player that had a score of 67-68=135? <|assistant|> SELECT "to_par" FROM "second_round" WHERE "score"='67-68=135';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "results_of_the_individual_jury_and_telev" ( "draw" real, "televote_points" text, "jury_points" text, "total" text, "final_points" text ); Question: What Televote Points had a Final Points score of 2? <|assistant|> SELECT "televote_points" FROM "results_of_the_individual_jury_and_telev" WHERE "final_points"='2';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "results_of_the_individual_jury_and_telev" ( "draw" real, "televote_points" text, "jury_points" text, "total" text, "final_points" text ); Question: Which Draw had 8 Televote Points? <|assistant|> SELECT COUNT("draw") FROM "results_of_the_individual_jury_and_telev" WHERE "televote_points"='8';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "results_of_the_individual_jury_and_telev" ( "draw" real, "televote_points" text, "jury_points" text, "total" text, "final_points" text ); Question: What was the Jury Points value when there were 3 Televote Points? <|assistant|> SELECT "jury_points" FROM "results_of_the_individual_jury_and_telev" WHERE "televote_points"='3';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "made_the_cut" ( "player" text, "country" text, "year_s_won" text, "total" real, "to_par" text, "finish" text ); Question: Which player was +4 to par and won the Open in 1995? <|assistant|> SELECT "player" FROM "made_the_cut" WHERE "to_par"='+4' AND "year_s_won"='1995';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "made_the_cut" ( "player" text, "country" text, "year_s_won" text, "total" real, "to_par" text, "finish" text ); Question: Which player has a to par of +8? <|assistant|> SELECT "player" FROM "made_the_cut" WHERE "to_par"='+8';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "repechage_2" ( "rank" real, "rowers" text, "country" text, "time" text, "notes" text ); Question: What country is ranked smaller than 2? <|assistant|> SELECT "country" FROM "repechage_2" WHERE "rank"<2;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "repechage_2" ( "rank" real, "rowers" text, "country" text, "time" text, "notes" text ); Question: What is the rank when the time is 6:50.48? <|assistant|> SELECT "rank" FROM "repechage_2" WHERE "time"='6:50.48';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "repechage_2" ( "rank" real, "rowers" text, "country" text, "time" text, "notes" text ); Question: What is the highest rank with the notes of sa/b, and a time of 6:39.07? <|assistant|> SELECT MAX("rank") FROM "repechage_2" WHERE "notes"='sa/b' AND "time"='6:39.07';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "repechage_2" ( "rank" real, "rowers" text, "country" text, "time" text, "notes" text ); Question: What shows for notes when rank is more than 4, and country is South Korea? <|assistant|> SELECT "notes" FROM "repechage_2" WHERE "rank">4 AND "country"='south korea';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "serialized_titles" ( "title" text, "author" text, "first_issue" text, "last_issue" text, "completed" text ); Question: What is the First Issue date of Bamboo Blade? <|assistant|> SELECT "first_issue" FROM "serialized_titles" WHERE "title"='bamboo blade';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "serialized_titles" ( "title" text, "author" text, "first_issue" text, "last_issue" text, "completed" text ); Question: What is the First issue date of the title with a Last Issue of July 2010? <|assistant|> SELECT "first_issue" FROM "serialized_titles" WHERE "last_issue"='july 2010';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "serialized_titles" ( "title" text, "author" text, "first_issue" text, "last_issue" text, "completed" text ); Question: What is the First Issue date of Soul Eater? <|assistant|> SELECT "first_issue" FROM "serialized_titles" WHERE "title"='soul eater';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "serialized_titles" ( "title" text, "author" text, "first_issue" text, "last_issue" text, "completed" text ); Question: Was the Title with a Last Issue of July 2010 completed? <|assistant|> SELECT "completed" FROM "serialized_titles" WHERE "last_issue"='july 2010';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "serialized_titles" ( "title" text, "author" text, "first_issue" text, "last_issue" text, "completed" text ); Question: What is the Author of the Title with a First Issue of September 2010? <|assistant|> SELECT "author" FROM "serialized_titles" WHERE "first_issue"='september 2010';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "serialized_titles" ( "title" text, "author" text, "first_issue" text, "last_issue" text, "completed" text ); Question: What is the Author of the Title with an Ongoing Last Issue? <|assistant|> SELECT "author" FROM "serialized_titles" WHERE "last_issue"='ongoing';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "torneo_apertura" ( "position" real, "team" text, "played" real, "wins" real, "draws" real, "losses" real, "scored" real, "conceded" real, "points" real ); Question: What is the highest number of losses for Presidente Hayes, when the draws were more than 4? <|assistant|> SELECT MAX("losses") FROM "torneo_apertura" WHERE "team"='presidente hayes' AND "draws">4;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "torneo_apertura" ( "position" real, "team" text, "played" real, "wins" real, "draws" real, "losses" real, "scored" real, "conceded" real, "points" real ); Question: What is the number of wins when position was larger than 6, and conceded was smaller than 19? <|assistant|> SELECT COUNT("wins") FROM "torneo_apertura" WHERE "position">6 AND "conceded"<19;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "torneo_apertura" ( "position" real, "team" text, "played" real, "wins" real, "draws" real, "losses" real, "scored" real, "conceded" real, "points" real ); Question: What is the number of losses when there were less than 4 draws, and points were 9? <|assistant|> SELECT "losses" FROM "torneo_apertura" WHERE "draws"<4 AND "points"=9;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "torneo_apertura" ( "position" real, "team" text, "played" real, "wins" real, "draws" real, "losses" real, "scored" real, "conceded" real, "points" real ); Question: What is the number of wins when scored was less than 26, and conceded was larger than 23? <|assistant|> SELECT SUM("wins") FROM "torneo_apertura" WHERE "scored"<26 AND "conceded">23;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "career_summary" ( "season" real, "series" text, "team" text, "races" real, "wins" real, "podiums" real, "points" real, "position" text ); Question: What was the series in season 2009? <|assistant|> SELECT "series" FROM "career_summary" WHERE "season"=2009;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "career_summary" ( "season" real, "series" text, "team" text, "races" real, "wins" real, "podiums" real, "points" real, "position" text ); Question: What was the lowest amount of wins before season 2009 for 97 points? <|assistant|> SELECT MIN("wins") FROM "career_summary" WHERE "points"=97 AND "season"<2009;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "career_summary" ( "season" real, "series" text, "team" text, "races" real, "wins" real, "podiums" real, "points" real, "position" text ); Question: How many wins had a podium larger than 6 after season 2008? <|assistant|> SELECT COUNT("wins") FROM "career_summary" WHERE "season">2008 AND "podiums">6;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "attendance" real ); Question: what is the date for the week larger than 1 and the opponent detroit lions? <|assistant|> SELECT "date" FROM "schedule" WHERE "week">1 AND "opponent"='detroit lions';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "schedule" ( "week" real, "date" text, "opponent" text, "result" text, "attendance" real ); Question: what is the lowest week when the attendance is 54,714? <|assistant|> SELECT MIN("week") FROM "schedule" WHERE "attendance"='54,714';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "heat_6" ( "rank" real, "lane" real, "athlete" text, "nationality" text, "time" real, "react" real ); Question: Which Athlete has a Reaction of 0.248? <|assistant|> SELECT "athlete" FROM "heat_6" WHERE "react"=0.248;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "heat_6" ( "rank" real, "lane" real, "athlete" text, "nationality" text, "time" real, "react" real ); Question: Which Rank has a Reaction of 0.198, and a Time smaller than 46.3? <|assistant|> SELECT MAX("rank") FROM "heat_6" WHERE "react"=0.198 AND "time"<46.3;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "heat_6" ( "rank" real, "lane" real, "athlete" text, "nationality" text, "time" real, "react" real ); Question: Which Lane has a Time larger than 47.83? <|assistant|> SELECT AVG("lane") FROM "heat_6" WHERE "time">47.83;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "heat_6" ( "rank" real, "lane" real, "athlete" text, "nationality" text, "time" real, "react" real ); Question: Which Reaction has a Rank smaller than 4, and a Nationality of trinidad and tobago, and a Time larger than 45.13? <|assistant|> SELECT AVG("react") FROM "heat_6" WHERE "rank"<4 AND "nationality"='trinidad and tobago' AND "time">45.13;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "competitive_history" ( "year" real, "competition_description" text, "location" text, "apparatus" text, "rank_final" real, "score_final" real, "rank_qualifying" real, "score_qualifying" real ); Question: Count the Rank-Final which has a Year larger than 2008, and an Apparatus of balance beam, and a Rank-Qualifying larger than 4? <|assistant|> SELECT COUNT("rank_final") FROM "competitive_history" WHERE "year">2008 AND "apparatus"='balance beam' AND "rank_qualifying">4;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "competitive_history" ( "year" real, "competition_description" text, "location" text, "apparatus" text, "rank_final" real, "score_final" real, "rank_qualifying" real, "score_qualifying" real ); Question: Which the lowest Score-Fina has a Rank-Final of 7 and a Year larger than 2009? <|assistant|> SELECT MIN("score_final") FROM "competitive_history" WHERE "rank_final"=7 AND "year">2009;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "competitive_history" ( "year" real, "competition_description" text, "location" text, "apparatus" text, "rank_final" real, "score_final" real, "rank_qualifying" real, "score_qualifying" real ); Question: Name the Year with a Rank-Final smaller than 2, an Apparatus of team, and a Score-Qualifying smaller than 248.275? <|assistant|> SELECT AVG("year") FROM "competitive_history" WHERE "rank_final"<2 AND "apparatus"='team' AND "score_qualifying"<248.275;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "fifth_round" ( "pick" real, "team" text, "player" text, "position" text, "college" text ); Question: What's the pick for the New York jets with a defensive end? <|assistant|> SELECT "pick" FROM "fifth_round" WHERE "position"='defensive end' AND "team"='new york jets';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "fifth_round" ( "pick" real, "team" text, "player" text, "position" text, "college" text ); Question: What's the pick for Georgia tech? <|assistant|> SELECT "pick" FROM "fifth_round" WHERE "college"='georgia tech';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "fifth_round" ( "pick" real, "team" text, "player" text, "position" text, "college" text ); Question: Who plays halfback? <|assistant|> SELECT "player" FROM "fifth_round" WHERE "position"='halfback';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "fifth_round" ( "pick" real, "team" text, "player" text, "position" text, "college" text ); Question: Who is the team for Washington College? <|assistant|> SELECT "team" FROM "fifth_round" WHERE "college"='washington';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "top_10_largest_crowds" ( "rank" real, "attendance" real, "visiting_team" text, "date" text, "result" text ); Question: What is the Rank of the game with an Attendance of 93,039? <|assistant|> SELECT COUNT("rank") FROM "top_10_largest_crowds" WHERE "attendance"='93,039';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "engines" ( "model" text, "engine" text, "displacement" text, "valvetrain" text, "fuel_system" text, "max_power_at_rpm" text, "max_torque_at_rpm" text, "years" text ); Question: What fuel system does the diesel engines model have? <|assistant|> SELECT "fuel_system" FROM "engines" WHERE "model"='diesel engines';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "engines" ( "model" text, "engine" text, "displacement" text, "valvetrain" text, "fuel_system" text, "max_power_at_rpm" text, "max_torque_at_rpm" text, "years" text ); Question: What is the displacement for the petrol engines model? <|assistant|> SELECT "displacement" FROM "engines" WHERE "model"='petrol engines';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "assembly_segments" ( "constituency_number" text, "name" text, "reserved_for_sc_st_none" text, "district" text, "number_of_electorates_2009" real ); Question: What is the size of the 2009 electorate for Gwalior Rural? <|assistant|> SELECT "number_of_electorates_2009" FROM "assembly_segments" WHERE "name"='gwalior rural';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "elimination_chamber_entrances_and_elimin" ( "eliminated" text, "wrestler" text, "entered" real, "eliminated_by" text, "time" text ); Question: Who was eliminated that entered after number 3 and lasted 35:55? <|assistant|> SELECT "eliminated" FROM "elimination_chamber_entrances_and_elimin" WHERE "entered">3 AND "time"='35:55';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "achievements" ( "year" real, "competition" text, "venue" text, "position" text, "notes" text ); Question: What is the average year in which the finish position was 13th? <|assistant|> SELECT AVG("year") FROM "achievements" WHERE "position"='13th';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "achievements" ( "year" real, "competition" text, "venue" text, "position" text, "notes" text ); Question: What is the average year for the Olympic Games? <|assistant|> SELECT AVG("year") FROM "achievements" WHERE "competition"='olympic games';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "release_history" ( "region" text, "date" text, "label" text, "format" text, "catalog" text ); Question: What is the Label of the September 20, 2008 release with Catalog number RTRADCD491? <|assistant|> SELECT "label" FROM "release_history" WHERE "catalog"='rtradcd491' AND "date"='september 20, 2008';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "release_history" ( "region" text, "date" text, "label" text, "format" text, "catalog" text ); Question: What is the Format of the September 22, 2008 release with Catalog number RTRADCD491? <|assistant|> SELECT "format" FROM "release_history" WHERE "catalog"='rtradcd491' AND "date"='september 22, 2008';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "release_history" ( "region" text, "date" text, "label" text, "format" text, "catalog" text ); Question: What is the Format of the release with Catalog number RTRADLP491? <|assistant|> SELECT "format" FROM "release_history" WHERE "catalog"='rtradlp491';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "release_history" ( "region" text, "date" text, "label" text, "format" text, "catalog" text ); Question: What is the Label of the Release with Catalog number 2508668? <|assistant|> SELECT "label" FROM "release_history" WHERE "catalog"='2508668';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "release_history" ( "region" text, "date" text, "label" text, "format" text, "catalog" text ); Question: What is the Format of the release with Catalog number 2508668? <|assistant|> SELECT "format" FROM "release_history" WHERE "catalog"='2508668';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "release_history" ( "region" text, "date" text, "label" text, "format" text, "catalog" text ); Question: What is the Region of the Warner Music Canada Label release? <|assistant|> SELECT "region" FROM "release_history" WHERE "label"='warner music canada';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "list_of_game_of_the_year_awards" ( "year" real, "game" text, "genre" text, "platform_s" text, "developer_s" text ); Question: Who were the developers for Portal? <|assistant|> SELECT "developer_s" FROM "list_of_game_of_the_year_awards" WHERE "game"='portal';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "list_of_game_of_the_year_awards" ( "year" real, "game" text, "genre" text, "platform_s" text, "developer_s" text ); Question: Who were the developers for the Action RPG made after 2010? <|assistant|> SELECT "developer_s" FROM "list_of_game_of_the_year_awards" WHERE "year">2010 AND "genre"='action rpg';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "airlines_based_in_changi" ( "airline" text, "iata" text, "icao" text, "callsign" text, "commenced_operations" real ); Question: Which Callsign has an IATA of tr? <|assistant|> SELECT "callsign" FROM "airlines_based_in_changi" WHERE "iata"='tr';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "airlines_based_in_changi" ( "airline" text, "iata" text, "icao" text, "callsign" text, "commenced_operations" real ); Question: Which Commenced operations have an Airline of valuair? <|assistant|> SELECT "commenced_operations" FROM "airlines_based_in_changi" WHERE "airline"='valuair';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "airlines_based_in_changi" ( "airline" text, "iata" text, "icao" text, "callsign" text, "commenced_operations" real ); Question: Which Commenced operations have an Airline of valuair? <|assistant|> SELECT MAX("commenced_operations") FROM "airlines_based_in_changi" WHERE "airline"='valuair';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "airlines_based_in_changi" ( "airline" text, "iata" text, "icao" text, "callsign" text, "commenced_operations" real ); Question: Which IATA has a ICAO of slk? <|assistant|> SELECT "iata" FROM "airlines_based_in_changi" WHERE "icao"='slk';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "most_watched_programmes" ( "rank" real, "series" text, "episode_title" text, "viewers" real, "date" text ); Question: How many Viewers have a Rank smaller than 2? <|assistant|> SELECT SUM("viewers") FROM "most_watched_programmes" WHERE "rank"<2;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "o" ( "township" text, "county" text, "pop_2010" real, "land_sqmi" real, "water_sqmi" real, "latitude" real, "longitude" real, "geo_id" real, "ansi_code" real ); Question: What is the longitude for the Township that has a ANSI code less than 1036534, a water (sqmi) of 0, and a GEO ID greater than 3809959540? <|assistant|> SELECT COUNT("longitude") FROM "o" WHERE "ansi_code"<1036534 AND "water_sqmi"=0 AND "geo_id">3809959540;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "o" ( "township" text, "county" text, "pop_2010" real, "land_sqmi" real, "water_sqmi" real, "latitude" real, "longitude" real, "geo_id" real, "ansi_code" real ); Question: What is the population in 2010 for the longitude of -97.578927? <|assistant|> SELECT COUNT("pop_2010") FROM "o" WHERE "longitude"=-97.578927;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "o" ( "township" text, "county" text, "pop_2010" real, "land_sqmi" real, "water_sqmi" real, "latitude" real, "longitude" real, "geo_id" real, "ansi_code" real ); Question: What is the total population in 2010 for the township located in Mountrail which has land less than 34.424 sq miles and a GEO ID less than 3806159940? <|assistant|> SELECT SUM("pop_2010") FROM "o" WHERE "land_sqmi"<34.424 AND "county"='mountrail' AND "geo_id"<3806159940;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "o" ( "township" text, "county" text, "pop_2010" real, "land_sqmi" real, "water_sqmi" real, "latitude" real, "longitude" real, "geo_id" real, "ansi_code" real ); Question: What is the highest recorded latitude for the township that has an ANSI code greater than 1759541 and a population in 2010 of 72? <|assistant|> SELECT MAX("latitude") FROM "o" WHERE "ansi_code">1759541 AND "pop_2010"=72;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "semifinal_2" ( "rank" real, "lane" real, "athlete" text, "nationality" text, "time" real ); Question: Which Athlete has a Rank larger than 1, and a Lane larger than 7, and a Nationality of china? <|assistant|> SELECT "athlete" FROM "semifinal_2" WHERE "rank">1 AND "lane">7 AND "nationality"='china';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "semifinal_2" ( "rank" real, "lane" real, "athlete" text, "nationality" text, "time" real ); Question: How many Lanes have a Time larger than 13.59, and a Rank larger than 8? <|assistant|> SELECT SUM("lane") FROM "semifinal_2" WHERE "time">13.59 AND "rank">8;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "semifinal_2" ( "rank" real, "lane" real, "athlete" text, "nationality" text, "time" real ); Question: How many lanes have a Nationality of france, and a Rank larger than 8? <|assistant|> SELECT SUM("lane") FROM "semifinal_2" WHERE "nationality"='france' AND "rank">8;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "game_spot" ( "year" real, "game" text, "genre" text, "platform_s" text, "developer_s" text ); Question: What game was developed by Nintendo for the Gamecube platform? <|assistant|> SELECT "game" FROM "game_spot" WHERE "developer_s"='nintendo' AND "platform_s"='gamecube';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "game_spot" ( "year" real, "game" text, "genre" text, "platform_s" text, "developer_s" text ); Question: What is the genre of Super Mario Galaxy? <|assistant|> SELECT "genre" FROM "game_spot" WHERE "game"='super mario galaxy';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "demography" ( "year" real, "population" real, "five_year_pct_change" text, "ten_year_pct_change" text, "rank_among_provinces" real ); Question: What is the average year having a rank among provinces over 5 and ten-year percentage change of 67.3? <|assistant|> SELECT AVG("year") FROM "demography" WHERE "ten_year_pct_change"='67.3' AND "rank_among_provinces">5;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "demography" ( "year" real, "population" real, "five_year_pct_change" text, "ten_year_pct_change" text, "rank_among_provinces" real ); Question: What is the highest population for the province having a rank under 5? <|assistant|> SELECT MAX("population") FROM "demography" WHERE "rank_among_provinces"<5;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "demography" ( "year" real, "population" real, "five_year_pct_change" text, "ten_year_pct_change" text, "rank_among_provinces" real ); Question: What is the number of population values having a rank among provinces under 5 with a five-year percentage change of 3.6? <|assistant|> SELECT COUNT("population") FROM "demography" WHERE "five_year_pct_change"='3.6' AND "rank_among_provinces"<5;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "demography" ( "year" real, "population" real, "five_year_pct_change" text, "ten_year_pct_change" text, "rank_among_provinces" real ); Question: What is the highest year having a ten-year percentage change of 7.9? <|assistant|> SELECT MAX("year") FROM "demography" WHERE "ten_year_pct_change"='7.9';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "1998_in_paraguayan_football" ( "date" text, "venue" text, "score" text, "comp" text, "report" text ); Question: What's the comp for 1998-04-22? <|assistant|> SELECT "comp" FROM "1998_in_paraguayan_football" WHERE "date"='1998-04-22';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "1998_in_paraguayan_football" ( "date" text, "venue" text, "score" text, "comp" text, "report" text ); Question: What's the score at Olympic Stadium Tokyo, Japan? <|assistant|> SELECT "score" FROM "1998_in_paraguayan_football" WHERE "venue"='olympic stadium tokyo, japan';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "1998_in_paraguayan_football" ( "date" text, "venue" text, "score" text, "comp" text, "report" text ); Question: What's the comp in Olympic Stadium Tokyo, Japan? <|assistant|> SELECT "comp" FROM "1998_in_paraguayan_football" WHERE "venue"='olympic stadium tokyo, japan';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "1998_in_paraguayan_football" ( "date" text, "venue" text, "score" text, "comp" text, "report" text ); Question: What's the report in King Baudouin Stadium Brussels, Belgium? <|assistant|> SELECT "report" FROM "1998_in_paraguayan_football" WHERE "venue"='king baudouin stadium brussels, belgium';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "eliminated_contestants_weigh_in_results" ( "contestant" text, "starting_weight_kg" real, "final_weight_kg" real, "weight_lost_kg" real, "percentage_lost" text, "position_out_of_eliminated_contestants" text ); Question: What is the Percentage Lost for the contestant with a starting weight above 102 kg who lost 46.9 kg? <|assistant|> SELECT "percentage_lost" FROM "eliminated_contestants_weigh_in_results" WHERE "starting_weight_kg">102 AND "weight_lost_kg"=46.9;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "semifinal_2" ( "rank" real, "lane" real, "name" text, "nationality" text, "time" text ); Question: What lane has a time of 1:57.71? <|assistant|> SELECT SUM("lane") FROM "semifinal_2" WHERE "time"='1:57.71';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "semifinal_2" ( "rank" real, "lane" real, "name" text, "nationality" text, "time" text ); Question: Who had a larger rank than 3, less than 6 lanes, and a time of 1:58.15? <|assistant|> SELECT "name" FROM "semifinal_2" WHERE "rank">3 AND "lane"<6 AND "time"='1:58.15';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "registered_births_and_deaths" ( "average_population_x_1000" real, "live_births" text, "deaths" text, "natural_change" text, "crude_birth_rate_per_1000" real, "crude_death_rate_per_1000" real, "natural_change_per_1000" real ); Question: Which Crude death rate (per 1000) has Deaths of 768, and a Crude birth rate (per 1000) smaller than 29.7? <|assistant|> SELECT MIN("crude_death_rate_per_1000") FROM "registered_births_and_deaths" WHERE "deaths"='768' AND "crude_birth_rate_per_1000"<29.7;<|endoftext|>