text
stringlengths
310
1.28k
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "results" ( "draw" real, "language" text, "artist" text, "song" text, "english_translation" text, "place" real, "points" real ); Question: How many Points were awarded to Sabahudin Kurt with a Draw is greater than 7? <|assistant|> SELECT "points" FROM "results" WHERE "draw">7 AND "artist"='sabahudin kurt';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "great_eastern_section" ( "number" text, "previous_number_s" real, "previous_class" text, "converted" real, "withdrawn" real, "disposal" text ); Question: How much Converted has a Number of 35, and a Withdrawn smaller than 1952? <|assistant|> SELECT COUNT("converted") FROM "great_eastern_section" WHERE "number"='35' AND "withdrawn"<1952;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "great_eastern_section" ( "number" text, "previous_number_s" real, "previous_class" text, "converted" real, "withdrawn" real, "disposal" text ); Question: How much Withdrawn has a Number of 42, and a Previous Number(s) larger than 68178? <|assistant|> SELECT SUM("withdrawn") FROM "great_eastern_section" WHERE "number"='42' AND "previous_number_s">68178;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "great_eastern_section" ( "number" text, "previous_number_s" real, "previous_class" text, "converted" real, "withdrawn" real, "disposal" text ); Question: Which Withdrawn has a Previous Class of j69, and a Previous Number(s) smaller than 68532, and a Converted larger than 1959? <|assistant|> SELECT MAX("withdrawn") FROM "great_eastern_section" WHERE "previous_class"='j69' AND "previous_number_s"<68532 AND "converted">1959;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "r" ( "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 average latitude for townships in Dickey county with water under 2.106 sqmi and population under 95? <|assistant|> SELECT AVG("latitude") FROM "r" WHERE "water_sqmi"<2.106 AND "county"='dickey' AND "pop_2010"<95;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "r" ( "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 GEO ID for land masses over 38.117 sq mi and over 2.065 sq mi of water? <|assistant|> SELECT MAX("geo_id") FROM "r" WHERE "land_sqmi">38.117 AND "water_sqmi">2.065;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "r" ( "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 number of GEO IDs for areas in Riggin township with water area over 0.587 sq mi and ANSI codes over 1759257? <|assistant|> SELECT COUNT("geo_id") FROM "r" WHERE "water_sqmi">0.587 AND "township"='riggin' AND "ansi_code">1759257;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "s_rebroadcaster_of_cbf_fm" ( "city_of_license" text, "identifier" text, "frequency" text, "power" text, "class" text, "rec_net" text ); Question: What's the class when the identifier is cbf-fm-14? <|assistant|> SELECT "class" FROM "s_rebroadcaster_of_cbf_fm" WHERE "identifier"='cbf-fm-14';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "s_rebroadcaster_of_cbf_fm" ( "city_of_license" text, "identifier" text, "frequency" text, "power" text, "class" text, "rec_net" text ); Question: What's the frequency when the identifier is cbf-fm-9? <|assistant|> SELECT "frequency" FROM "s_rebroadcaster_of_cbf_fm" WHERE "identifier"='cbf-fm-9';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "s_rebroadcaster_of_cbf_fm" ( "city_of_license" text, "identifier" text, "frequency" text, "power" text, "class" text, "rec_net" text ); Question: What's the RECNet when the identifier is cbf-fm-20? <|assistant|> SELECT "rec_net" FROM "s_rebroadcaster_of_cbf_fm" WHERE "identifier"='cbf-fm-20';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "s_rebroadcaster_of_cbf_fm" ( "city_of_license" text, "identifier" text, "frequency" text, "power" text, "class" text, "rec_net" text ); Question: What's the RECNet when the power is 199 watts? <|assistant|> SELECT "rec_net" FROM "s_rebroadcaster_of_cbf_fm" WHERE "power"='199 watts';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "s_rebroadcaster_of_cbf_fm" ( "city_of_license" text, "identifier" text, "frequency" text, "power" text, "class" text, "rec_net" text ); Question: What's the frequency when the identifier is cbf-fm-14 having a class of A? <|assistant|> SELECT "frequency" FROM "s_rebroadcaster_of_cbf_fm" WHERE "class"='a' AND "identifier"='cbf-fm-14';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "digital_television" ( "transmitter" text, "bbca" real, "bbcb" text, "d3_4" text, "arqa" text, "arqb" text, "pol" text, "a_g" text ); Question: What is the A.G. value associated with D3&4 of 46 and transmitter of Seaham? <|assistant|> SELECT "a_g" FROM "digital_television" WHERE "d3_4"='46' AND "transmitter"='seaham';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "digital_television" ( "transmitter" text, "bbca" real, "bbcb" text, "d3_4" text, "arqa" text, "arqb" text, "pol" text, "a_g" text ); Question: What is the AG value associated with a D3&4 of 41? <|assistant|> SELECT "a_g" FROM "digital_television" WHERE "d3_4"='41';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "singles" ( "year" real, "title" text, "billboard_hot_100" text, "uk_singles_chart" text, "album" text ); Question: What was the billboard hot 100 with an album bust a nut, and the title of "need your lovin' (re-release)"? <|assistant|> SELECT "billboard_hot_100" FROM "singles" WHERE "album"='bust a nut' AND "title"='\"need your lovin'' (re-release)\"';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "singles" ( "year" real, "title" text, "billboard_hot_100" text, "uk_singles_chart" text, "album" text ); Question: What is the UK singles chart for the album psychotic supper, in the year 1992, with a title of "song & emotion"? <|assistant|> SELECT "uk_singles_chart" FROM "singles" WHERE "album"='psychotic supper' AND "year"=1992 AND "title"='\"song & emotion\"';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "guest_appearances" ( "artist" text, "album" text, "track_s" text, "date" text, "label" text ); Question: which Label is in 15 december 1992? <|assistant|> SELECT "label" FROM "guest_appearances" WHERE "date"='15 december 1992';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "guest_appearances" ( "artist" text, "album" text, "track_s" text, "date" text, "label" text ); Question: Which Album has an Artist of various artists (compilation), and a Label of laface? <|assistant|> SELECT "album" FROM "guest_appearances" WHERE "artist"='various artists (compilation)' AND "label"='laface';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "guest_appearances" ( "artist" text, "album" text, "track_s" text, "date" text, "label" text ); Question: When has an Album of l'un n'empêche pas l'autre? <|assistant|> SELECT "date" FROM "guest_appearances" WHERE "album"='l''un n''empêche pas l''autre';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "guest_appearances" ( "artist" text, "album" text, "track_s" text, "date" text, "label" text ); Question: Which Track(s) is on 18 november 1985? <|assistant|> SELECT "track_s" FROM "guest_appearances" WHERE "date"='18 november 1985';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "guest_appearances" ( "artist" text, "album" text, "track_s" text, "date" text, "label" text ); Question: Which Artist has a Track(s) of " evilmainya "? <|assistant|> SELECT "artist" FROM "guest_appearances" WHERE "track_s"='\" evilmainya \"';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "guest_appearances" ( "artist" text, "album" text, "track_s" text, "date" text, "label" text ); Question: Which Label that has an Album of so red the rose? <|assistant|> SELECT "label" FROM "guest_appearances" WHERE "album"='so red the rose';<|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 least lane number that Natalie Coughlin was in when she was ranked greater than 1? <|assistant|> SELECT MIN("lane") FROM "semifinal_2" WHERE "name"='natalie coughlin' AND "rank">1;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "semifinal_a_b_1" ( "rank" real, "athlete" text, "country" text, "time" text, "notes" text ); Question: Who is the Athlete with a rowing Time of 6:36.05? <|assistant|> SELECT "athlete" FROM "semifinal_a_b_1" WHERE "time"='6:36.05';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "main_setlist" ( "year" real, "song" text, "artist" text, "genre" text, "band_tour_venue" text, "exportable" text ); Question: What song was made by the sex pistols? <|assistant|> SELECT "song" FROM "main_setlist" WHERE "artist"='sex pistols';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "main_setlist" ( "year" real, "song" text, "artist" text, "genre" text, "band_tour_venue" text, "exportable" text ); Question: What song has the band tour vnue of 6. tool (usa) encore? <|assistant|> SELECT "song" FROM "main_setlist" WHERE "band_tour_venue"='6. tool (usa) encore';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "qualified_competitors" ( "position" real, "gymnast" text, "a_score" real, "b_score" real, "total" real ); Question: What is the total when the A score was less than 6.6, and the B score was 8.925? <|assistant|> SELECT "total" FROM "qualified_competitors" WHERE "a_score"<6.6 AND "b_score"=8.925;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "qualified_competitors" ( "position" real, "gymnast" text, "a_score" real, "b_score" real, "total" real ); Question: What total has a position smaller than 4, a B score higher than 9.125, and an A score less than 6.6? <|assistant|> SELECT AVG("total") FROM "qualified_competitors" WHERE "position"<4 AND "b_score">9.125 AND "a_score"<6.6;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "second_round_proper" ( "tie_no" text, "home_team" text, "score" text, "away_team" text, "date" text ); Question: What is the score when watford was the away team? <|assistant|> SELECT "score" FROM "second_round_proper" WHERE "away_team"='watford';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "second_round_proper" ( "tie_no" text, "home_team" text, "score" text, "away_team" text, "date" text ); Question: What is the score when york city was the home team? <|assistant|> SELECT "score" FROM "second_round_proper" WHERE "home_team"='york city';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "regular_season" ( "game" real, "date" text, "opponent" text, "score" text, "high_points" text, "high_rebounds" text, "high_assists" text, "location_attendance" text, "record" text ); Question: What score has a game greater than 29, with 24-6 as the record? <|assistant|> SELECT "score" FROM "regular_season" WHERE "game">29 AND "record"='24-6';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "regular_season" ( "game" real, "date" text, "opponent" text, "score" text, "high_points" text, "high_rebounds" text, "high_assists" text, "location_attendance" text, "record" text ); Question: What record has @ detroit as the opponent? <|assistant|> SELECT "record" FROM "regular_season" WHERE "opponent"='@ detroit';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "regular_season" ( "game" real, "date" text, "opponent" text, "score" text, "high_points" text, "high_rebounds" text, "high_assists" text, "location_attendance" text, "record" text ); Question: What high assists have McWilliams-franklin (22) as the high points? <|assistant|> SELECT "high_assists" FROM "regular_season" WHERE "high_points"='mcwilliams-franklin (22)';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "regular_season" ( "game" real, "date" text, "opponent" text, "score" text, "high_points" text, "high_rebounds" text, "high_assists" text, "location_attendance" text, "record" text ); Question: What high assists have uic pavilion 3,520 as the location/attendance? <|assistant|> SELECT "high_assists" FROM "regular_season" WHERE "location_attendance"='uic pavilion 3,520';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "regular_season" ( "game" real, "date" text, "opponent" text, "score" text, "high_points" text, "high_rebounds" text, "high_assists" text, "location_attendance" text, "record" text ); Question: What game has jones (10) as the high rebounds? <|assistant|> SELECT "game" FROM "regular_season" WHERE "high_rebounds"='jones (10)';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "ivy_bridge_quad_core_22_nm" ( "model_number" text, "s_spec_number" text, "cores" text, "frequency" text, "turbo" text, "l2_cache" text, "l3_cache" text, "gpu_model" text, "gpu_frequency" text, "socket" text, "i_o_bus" text, "release_date" text, "part_number_s" text, "release_price_usd" text ); Question: How many cores does the processor with a release price of $426 have? <|assistant|> SELECT "cores" FROM "ivy_bridge_quad_core_22_nm" WHERE "release_price_usd"='$426';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "ivy_bridge_quad_core_22_nm" ( "model_number" text, "s_spec_number" text, "cores" text, "frequency" text, "turbo" text, "l2_cache" text, "l3_cache" text, "gpu_model" text, "gpu_frequency" text, "socket" text, "i_o_bus" text, "release_date" text, "part_number_s" text, "release_price_usd" text ); Question: What was the frequency of the Core i7-3610QE? <|assistant|> SELECT "frequency" FROM "ivy_bridge_quad_core_22_nm" WHERE "model_number"='core i7-3610qe';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "ivy_bridge_quad_core_22_nm" ( "model_number" text, "s_spec_number" text, "cores" text, "frequency" text, "turbo" text, "l2_cache" text, "l3_cache" text, "gpu_model" text, "gpu_frequency" text, "socket" text, "i_o_bus" text, "release_date" text, "part_number_s" text, "release_price_usd" text ); Question: How many cores does the processor released in April 2012 with a price of $393 and part number av8063801117503 have? <|assistant|> SELECT "cores" FROM "ivy_bridge_quad_core_22_nm" WHERE "release_date"='april 2012' AND "release_price_usd"='$393' AND "part_number_s"='av8063801117503';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "most_densely_populated_islands_over_1_00" ( "island" text, "country" text, "population" text, "area_km" text, "density_per_km" text ); Question: What is Japan's Area km²? <|assistant|> SELECT "area_km" FROM "most_densely_populated_islands_over_1_00" WHERE "country"='japan';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "most_densely_populated_islands_over_1_00" ( "island" text, "country" text, "population" text, "area_km" text, "density_per_km" text ); Question: Which island has a density (per km²) of 1,368? <|assistant|> SELECT "island" FROM "most_densely_populated_islands_over_1_00" WHERE "density_per_km"='1,368';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "most_densely_populated_islands_over_1_00" ( "island" text, "country" text, "population" text, "area_km" text, "density_per_km" text ); Question: Which country has a density (per km²) of 6,814? <|assistant|> SELECT "country" FROM "most_densely_populated_islands_over_1_00" WHERE "density_per_km"='6,814';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "most_densely_populated_islands_over_1_00" ( "island" text, "country" text, "population" text, "area_km" text, "density_per_km" text ); Question: Which island has a population of 9,520 (2000)? <|assistant|> SELECT "island" FROM "most_densely_populated_islands_over_1_00" WHERE "population"='9,520 (2000)';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "most_densely_populated_islands_over_1_00" ( "island" text, "country" text, "population" text, "area_km" text, "density_per_km" text ); Question: What is the area km² for a population of 99,685 (2008)? <|assistant|> SELECT "area_km" FROM "most_densely_populated_islands_over_1_00" WHERE "population"='99,685 (2008)';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "most_densely_populated_islands_over_1_00" ( "island" text, "country" text, "population" text, "area_km" text, "density_per_km" text ); Question: Which island is in the United Kingdom? <|assistant|> SELECT "island" FROM "most_densely_populated_islands_over_1_00" WHERE "country"='united kingdom';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "pitchers" ( "season" text, "pitcher" text, "decision" text, "opponent" text, "location" text ); Question: Who is the pitcher from the 1983 season in location Kingdome? <|assistant|> SELECT "pitcher" FROM "pitchers" WHERE "location"='kingdome' AND "season"='1983';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "pitchers" ( "season" text, "pitcher" text, "decision" text, "opponent" text, "location" text ); Question: Who is the pitcher from the 1994 season that had the Cleveland Indians as an opponent? <|assistant|> SELECT "pitcher" FROM "pitchers" WHERE "opponent"='cleveland indians' AND "season"='1994';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "pitchers" ( "season" text, "pitcher" text, "decision" text, "opponent" text, "location" text ); Question: Who is the opponent for the 2011 season with a decision of W? <|assistant|> SELECT "opponent" FROM "pitchers" WHERE "decision"='w' AND "season"='2011';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "pitchers" ( "season" text, "pitcher" text, "decision" text, "opponent" text, "location" text ); Question: What season was played at Safeco Field, against the Boston Red Sox, with a decision of L? <|assistant|> SELECT "season" FROM "pitchers" WHERE "location"='safeco field' AND "decision"='l' AND "opponent"='boston red sox';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "pitchers" ( "season" text, "pitcher" text, "decision" text, "opponent" text, "location" text ); Question: What was the decision for the 1983 season for the game played against the New York Yankees? <|assistant|> SELECT "decision" FROM "pitchers" WHERE "opponent"='new york yankees' AND "season"='1983';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "common_floppy_disk_formats_logical_chara" ( "platform" text, "size" text, "density" text, "bytes_sector" real, "sectors_track" text, "tracks_side" text, "sides" real, "capacity" text, "encoding" text ); Question: what is the encoding when the tracks/side is 80 and sectors/track is 11? <|assistant|> SELECT "encoding" FROM "common_floppy_disk_formats_logical_chara" WHERE "tracks_side"='80' AND "sectors_track"='11';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "medal_table" ( "rank" real, "nation" text, "gold" real, "silver" real, "bronze" real, "total" real ); Question: What is the highest bronze for less than 2 total trophies? <|assistant|> SELECT MAX("bronze") FROM "medal_table" WHERE "total"<2;<|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_won" real, "total" real, "to_par" text, "finish" text ); Question: Which Total has a Finish of t64, and a Year won larger than 2006? <|assistant|> SELECT MAX("total") FROM "made_the_cut" WHERE "finish"='t64' AND "year_won">2006;<|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_won" real, "total" real, "to_par" text, "finish" text ); Question: Which year won has a Finish of t24, and a Country of england? <|assistant|> SELECT AVG("year_won") FROM "made_the_cut" WHERE "finish"='t24' AND "country"='england';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "medals_table" ( "rank" real, "nation" text, "gold" real, "silver" real, "bronze" real, "total" real ); Question: What is the smallest bronze value for countries with totals over 2, golds of 0, silvers under 1, and ranks over 10? <|assistant|> SELECT MIN("bronze") FROM "medals_table" WHERE "total">2 AND "silver"<1 AND "rank">10 AND "gold"<0;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "membership" ( "school" text, "location" text, "mascot" text, "county" real, "enrollment" text, "ihsaa_class" text, "year_joined" real, "previous_conference" text ); Question: Which school has an enrollment of A and had lost river as their previous conference? <|assistant|> SELECT "school" FROM "membership" WHERE "previous_conference"='lost river' AND "enrollment"='a';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "membership" ( "school" text, "location" text, "mascot" text, "county" real, "enrollment" text, "ihsaa_class" text, "year_joined" real, "previous_conference" text ); Question: What is the average year joined of the 277 county? <|assistant|> SELECT AVG("year_joined") FROM "membership" WHERE "county"=277;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "membership" ( "school" text, "location" text, "mascot" text, "county" real, "enrollment" text, "ihsaa_class" text, "year_joined" real, "previous_conference" text ); Question: What is the IHSAA class of the county that is less than 228? <|assistant|> SELECT "ihsaa_class" FROM "membership" WHERE "county"<228;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "engineering" ( "engine" text, "production" text, "transmission" text, "power" text, "torque" text, "acceleration_0_100km_h_0_62mph" text, "top_speed" text ); Question: What is the engine when the transmission was 4-speed automatic, and acceleration 0–100km/h (0–62mph) was 10.4 s? <|assistant|> SELECT "engine" FROM "engineering" WHERE "transmission"='4-speed automatic' AND "acceleration_0_100km_h_0_62mph"='10.4 s';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "engineering" ( "engine" text, "production" text, "transmission" text, "power" text, "torque" text, "acceleration_0_100km_h_0_62mph" text, "top_speed" text ); Question: What is the Power when the acceleration 0–100km/h (0–62mph) is 9.1 s? <|assistant|> SELECT "power" FROM "engineering" WHERE "acceleration_0_100km_h_0_62mph"='9.1 s';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "engineering" ( "engine" text, "production" text, "transmission" text, "power" text, "torque" text, "acceleration_0_100km_h_0_62mph" text, "top_speed" text ); Question: What is the transmission when the engine is 2.0l, and acceleration 0–100km/h (0–62mph) is 10.5 s? <|assistant|> SELECT "transmission" FROM "engineering" WHERE "engine"='2.0l' AND "acceleration_0_100km_h_0_62mph"='10.5 s';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "engineering" ( "engine" text, "production" text, "transmission" text, "power" text, "torque" text, "acceleration_0_100km_h_0_62mph" text, "top_speed" text ); Question: What is the production when engine is 2.7l, and acceleration 0–100km/h (0–62mph) is 8.5 s? <|assistant|> SELECT "production" FROM "engineering" WHERE "engine"='2.7l' AND "acceleration_0_100km_h_0_62mph"='8.5 s';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "engineering" ( "engine" text, "production" text, "transmission" text, "power" text, "torque" text, "acceleration_0_100km_h_0_62mph" text, "top_speed" text ); Question: What is the transmission when the production was 2002-2005? <|assistant|> SELECT "transmission" FROM "engineering" WHERE "production"='2002-2005';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "engineering" ( "engine" text, "production" text, "transmission" text, "power" text, "torque" text, "acceleration_0_100km_h_0_62mph" text, "top_speed" text ); Question: What is the acceleration 0–100km/h (0–62mph) when the transmission is 5-speed manual? <|assistant|> SELECT "acceleration_0_100km_h_0_62mph" FROM "engineering" WHERE "transmission"='5-speed manual';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "giant_bomb" ( "year" real, "game" text, "genre" text, "platform_s" text, "developer_s" text ); Question: What is the highest year for the Bethesda Game Studios Developer? <|assistant|> SELECT MAX("year") FROM "giant_bomb" WHERE "developer_s"='bethesda game studios';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "giant_bomb" ( "year" real, "game" text, "genre" text, "platform_s" text, "developer_s" text ); Question: What is the lowest year for the game called The Elder Scrolls v: Skyrim? <|assistant|> SELECT MIN("year") FROM "giant_bomb" WHERE "game"='the elder scrolls v: skyrim';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "giant_bomb" ( "year" real, "game" text, "genre" text, "platform_s" text, "developer_s" text ); Question: What game was developed by Naughty Dog? <|assistant|> SELECT "genre" FROM "giant_bomb" WHERE "developer_s"='naughty dog';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "current_medical_schools_in_the_caribbean" ( "country_territory" text, "established" real, "degree" text, "regional_offshore" text, "imed_avicenna_listed" text ); Question: What is the imed/avicenna listed for a medical school offshore in saint kitts and nevis which was established before 2000 and will give you an MD? <|assistant|> SELECT "imed_avicenna_listed" FROM "current_medical_schools_in_the_caribbean" WHERE "regional_offshore"='offshore' AND "country_territory"='saint kitts and nevis' AND "degree"='md' AND "established"<2000;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "current_medical_schools_in_the_caribbean" ( "country_territory" text, "established" real, "degree" text, "regional_offshore" text, "imed_avicenna_listed" text ); Question: What country has a medical school established in 1969 with both an IMED and avicenna? <|assistant|> SELECT "country_territory" FROM "current_medical_schools_in_the_caribbean" WHERE "imed_avicenna_listed"='both' AND "established"=1969;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "current_medical_schools_in_the_caribbean" ( "country_territory" text, "established" real, "degree" text, "regional_offshore" text, "imed_avicenna_listed" text ); Question: What is the average year that the medical school in dominican republic was established? <|assistant|> SELECT AVG("established") FROM "current_medical_schools_in_the_caribbean" WHERE "country_territory"='dominican republic';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "2010_ladder" ( "sunrayia_fl" text, "wins" real, "byes" real, "losses" real, "draws" real, "against" real ); Question: What are the most wins with byes more than 0 and 1637 against? <|assistant|> SELECT MAX("wins") FROM "2010_ladder" WHERE "against"=1637 AND "byes">0;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "2010_ladder" ( "sunrayia_fl" text, "wins" real, "byes" real, "losses" real, "draws" real, "against" real ); Question: What are the total byes for the Red Cliffs with more than 4 losses and more than 2422 against? <|assistant|> SELECT COUNT("byes") FROM "2010_ladder" WHERE "losses">4 AND "sunrayia_fl"='red cliffs' AND "against">2422;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "2010_ladder" ( "sunrayia_fl" text, "wins" real, "byes" real, "losses" real, "draws" real, "against" real ); Question: What's the total wins for Wentworth with less than 0 byes? <|assistant|> SELECT COUNT("wins") FROM "2010_ladder" WHERE "sunrayia_fl"='wentworth' AND "byes"<0;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "fa_premier_league" ( "date" text, "opponent" text, "venue" text, "result" text, "attendance" real ); Question: Which venue had an opponent of Sunderland and a result of a 1-1 draw? <|assistant|> SELECT "venue" FROM "fa_premier_league" WHERE "opponent"='sunderland' AND "result"='1-1';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "fa_premier_league" ( "date" text, "opponent" text, "venue" text, "result" text, "attendance" real ); Question: What is the number of attendance values for ties having an opponent of Middlesbrough and result of 3-1? <|assistant|> SELECT COUNT("attendance") FROM "fa_premier_league" WHERE "opponent"='middlesbrough' AND "result"='3-1';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "fa_premier_league" ( "date" text, "opponent" text, "venue" text, "result" text, "attendance" real ); Question: Which venue ended in a 3-0 result? <|assistant|> SELECT "venue" FROM "fa_premier_league" WHERE "result"='3-0';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "football_league_first_division" ( "date" text, "opponent" text, "venue" text, "result" text, "attendance" real ); Question: Where was a 0-5 game played? <|assistant|> SELECT "venue" FROM "football_league_first_division" WHERE "result"='0-5';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "season" ( "rank" real, "player" text, "county" text, "tally" text, "total" real, "matches" real, "average" real ); Question: What is the average rank of a player with fewer than 3 matches? <|assistant|> SELECT AVG("rank") FROM "season" WHERE "matches"<3;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "game_log" ( "game" text, "date" text, "opponent" text, "score" text, "location_attendance" text, "record" text ); Question: Who was the opponent on April 21? <|assistant|> SELECT "opponent" FROM "game_log" WHERE "date"='april 21';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "game_log" ( "game" text, "date" text, "opponent" text, "score" text, "location_attendance" text, "record" text ); Question: What's the record on April 12 when the location was The Omni? <|assistant|> SELECT "record" FROM "game_log" WHERE "location_attendance"='the omni' AND "date"='april 12';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "game_log" ( "game" text, "date" text, "opponent" text, "score" text, "location_attendance" text, "record" text ); Question: What date was the score "score"? <|assistant|> SELECT "date" FROM "game_log" WHERE "score"='score';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "game_log" ( "game" text, "date" text, "opponent" text, "score" text, "location_attendance" text, "record" text ); Question: What was the score on April 12? <|assistant|> SELECT "score" FROM "game_log" WHERE "date"='april 12';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "game_log" ( "game" text, "date" text, "opponent" text, "score" text, "location_attendance" text, "record" text ); Question: What's the score of game 77? <|assistant|> SELECT "score" FROM "game_log" WHERE "game"='77';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "game_log" ( "game" text, "date" text, "opponent" text, "score" text, "location_attendance" text, "record" text ); Question: What date had a record of 43-34? <|assistant|> SELECT "date" FROM "game_log" WHERE "record"='43-34';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "results_of_heat_2" ( "draw" real, "artist" text, "song" text, "percentage" text, "place" real ); Question: What Artist had a Percentage of 17.14%? <|assistant|> SELECT "artist" FROM "results_of_heat_2" WHERE "percentage"='17.14%';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "results_of_heat_2" ( "draw" real, "artist" text, "song" text, "percentage" text, "place" real ); Question: What Percentage has a Place of 5? <|assistant|> SELECT "percentage" FROM "results_of_heat_2" WHERE "place"=5;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "references" ( "hr_number" real, "name" text, "lms_number" real, "br_number" text, "withdrawn" text ); Question: Which BR number has an LMS number over 14768? <|assistant|> SELECT "br_number" FROM "references" WHERE "lms_number">14768;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "s_rebroadcaster_of_cjbc" ( "city_of_license" text, "identifier" text, "frequency" text, "power" text, "class" text, "rec_net" text ); Question: what is the frequency when the city of license is belleville? <|assistant|> SELECT "frequency" FROM "s_rebroadcaster_of_cjbc" WHERE "city_of_license"='belleville';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "s_rebroadcaster_of_cjbc" ( "city_of_license" text, "identifier" text, "frequency" text, "power" text, "class" text, "rec_net" text ); Question: what is the class when the power is 22500 watts? <|assistant|> SELECT "class" FROM "s_rebroadcaster_of_cjbc" WHERE "power"='22500 watts';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "s_rebroadcaster_of_cjbc" ( "city_of_license" text, "identifier" text, "frequency" text, "power" text, "class" text, "rec_net" text ); Question: what is the class when the identifier is cjbc-1-fm? <|assistant|> SELECT "class" FROM "s_rebroadcaster_of_cjbc" WHERE "identifier"='cjbc-1-fm';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "s_rebroadcaster_of_cjbc" ( "city_of_license" text, "identifier" text, "frequency" text, "power" text, "class" text, "rec_net" text ); Question: what is the recnet when the city of license is peterborough? <|assistant|> SELECT "rec_net" FROM "s_rebroadcaster_of_cjbc" WHERE "city_of_license"='peterborough';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "s_rebroadcaster_of_cjbc" ( "city_of_license" text, "identifier" text, "frequency" text, "power" text, "class" text, "rec_net" text ); Question: what is the power when the city of license is belleville? <|assistant|> SELECT "power" FROM "s_rebroadcaster_of_cjbc" WHERE "city_of_license"='belleville';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "s_rebroadcaster_of_cjbc" ( "city_of_license" text, "identifier" text, "frequency" text, "power" text, "class" text, "rec_net" text ); Question: what is the identifier when the power is 22500 watts? <|assistant|> SELECT "identifier" FROM "s_rebroadcaster_of_cjbc" WHERE "power"='22500 watts';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "schedule" ( "game" real, "date" text, "opponent" text, "result" text, "dolphins_points" real, "opponents" real, "record" text, "attendance" real ); Question: What is the Opponents in the game with a Date of nov. 25? <|assistant|> SELECT MIN("opponents") FROM "schedule" WHERE "date"='nov. 25';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "all_time_records" ( "name" text, "games" text, "a_league" text, "finals" text, "goals" real, "assists" real, "years" text ); Question: How many games does leandro love have? <|assistant|> SELECT "games" FROM "all_time_records" WHERE "name"='leandro love';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "all_time_records" ( "name" text, "games" text, "a_league" text, "finals" text, "goals" real, "assists" real, "years" text ); Question: What is the lowest number of goals joe keenan, who has more than 1 assists, had in 2007/08? <|assistant|> SELECT MIN("goals") FROM "all_time_records" WHERE "years"='2007/08' AND "name"='joe keenan' AND "assists">1;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "all_time_records" ( "name" text, "games" text, "a_league" text, "finals" text, "goals" real, "assists" real, "years" text ); Question: What is the lowest number of goals of the player with 9 (0) games and less than 0 assists? <|assistant|> SELECT MIN("goals") FROM "all_time_records" WHERE "games"='9 (0)' AND "assists"<0;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "all_time_records" ( "name" text, "games" text, "a_league" text, "finals" text, "goals" real, "assists" real, "years" text ); Question: How many finals had more than 0 goals and 8 assists? <|assistant|> SELECT "finals" FROM "all_time_records" WHERE "goals">0 AND "assists"=8;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "heats" ( "rank" real, "heat" real, "lane" real, "name" text, "nationality" text, "time" text ); Question: When the nationality is united states, and the time is 58.06, and the heat is larger than 5 what is the lowest rank? <|assistant|> SELECT MIN("rank") FROM "heats" WHERE "nationality"='united states' AND "time"='58.06' AND "heat">5;<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "heats" ( "rank" real, "heat" real, "lane" real, "name" text, "nationality" text, "time" text ); Question: What is the highest rank when the lane is larger than 6, and the heat is 3, and the nationality is colombia? <|assistant|> SELECT MAX("rank") FROM "heats" WHERE "lane">6 AND "heat"=3 AND "nationality"='colombia';<|endoftext|>
<|system|> You are an expert SQL query generator. Only output valid SQL. <|user|> ### Database Schema CREATE TABLE "heats" ( "rank" real, "heat" real, "lane" real, "name" text, "nationality" text, "time" text ); Question: What is the total lane for a heat larger than 7? <|assistant|> SELECT COUNT("lane") FROM "heats" WHERE "heat">7;<|endoftext|>