chat_prompt
stringlengths
438
1.53k
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_23649244_1\" (\n \"song_1_title\" text,\n \"artist_1\" text,\n \"song_2_title\" text,\n \"artist_2\" text,\n \"mix_artist\" text,\n \"guitar_part\" text,\n \"level\" text\n);\n\nQuestion: Which mix artists have shlomo as artist 1?" }, { "role": "assistant", "content": "SELECT \"mix_artist\" FROM \"table1_23649244_1\" WHERE \"artist_1\"='Shlomo';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"professional_league_1951_present\" (\n \"season\" real,\n \"champion\" text,\n \"count\" real,\n \"runners_up\" text,\n \"third_place\" text,\n \"top_scorer\" text,\n \"top_scorers_club\" text,\n \"goals\" text\n);\n\nQuestion: How many season had Melgar as a champion?" }, { "role": "assistant", "content": "SELECT COUNT(\"season\") FROM \"professional_league_1951_present\" WHERE \"champion\"='Melgar';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"professional_league_1951_present\" (\n \"season\" real,\n \"champion\" text,\n \"count\" real,\n \"runners_up\" text,\n \"third_place\" text,\n \"top_scorer\" text,\n \"top_scorers_club\" text,\n \"goals\" text\n);\n\nQuestion: What year was the season with the top scoring club being Sporting Cristal and the champion was Universitario?" }, { "role": "assistant", "content": "SELECT \"season\" FROM \"professional_league_1951_present\" WHERE \"top_scorers_club\"='Sporting Cristal' AND \"champion\"='Universitario';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"professional_league_1951_present\" (\n \"season\" real,\n \"champion\" text,\n \"count\" real,\n \"runners_up\" text,\n \"third_place\" text,\n \"top_scorer\" text,\n \"top_scorers_club\" text,\n \"goals\" text\n);\n\nQuestion: Who was in third place in the 1980 season?" }, { "role": "assistant", "content": "SELECT \"third_place\" FROM \"professional_league_1951_present\" WHERE \"season\"=1980;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"year_by_year\" (\n \"year\" real,\n \"division\" real,\n \"league\" text,\n \"regular_season\" text,\n \"playoffs\" text,\n \"open_cup\" text\n);\n\nQuestion: Name the open cup for usl pdl for did not qualify" }, { "role": "assistant", "content": "SELECT \"open_cup\" FROM \"year_by_year\" WHERE \"league\"='USL PDL' AND \"playoffs\"='Did not qualify';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"year_by_year\" (\n \"year\" real,\n \"division\" real,\n \"league\" text,\n \"regular_season\" text,\n \"playoffs\" text,\n \"open_cup\" text\n);\n\nQuestion: Name the total number of open cup for 1996" }, { "role": "assistant", "content": "SELECT COUNT(\"open_cup\") FROM \"year_by_year\" WHERE \"year\"=1996;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"year_by_year\" (\n \"year\" real,\n \"division\" real,\n \"league\" text,\n \"regular_season\" text,\n \"playoffs\" text,\n \"open_cup\" text\n);\n\nQuestion: Name the open cup for division finals" }, { "role": "assistant", "content": "SELECT \"open_cup\" FROM \"year_by_year\" WHERE \"playoffs\"='Division Finals';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: Name the position for 2.16" }, { "role": "assistant", "content": "SELECT \"position\" FROM \"fiba_euro_basket_2009_squads\" WHERE \"height_m\"='2.16';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: Name the number for 1.96 height" }, { "role": "assistant", "content": "SELECT \"no\" FROM \"fiba_euro_basket_2009_squads\" WHERE \"height_m\"='1.96';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: Name the height for number 7" }, { "role": "assistant", "content": "SELECT \"height_m\" FROM \"fiba_euro_basket_2009_squads\" WHERE \"no\"=7;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: name the player for number 5" }, { "role": "assistant", "content": "SELECT \"player\" FROM \"fiba_euro_basket_2009_squads\" WHERE \"no\"=5;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: Identify every player's height in meters if the player is exactly 6' 07\" tall in feet" }, { "role": "assistant", "content": "SELECT \"height_m\" FROM \"fiba_euro_basket_2009_squads\" WHERE \"height_f\"='6'' 07\\\"';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: For all players playing at the center, list the height in feet." }, { "role": "assistant", "content": "SELECT \"height_f\" FROM \"fiba_euro_basket_2009_squads\" WHERE \"position\"='Center';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: Display the serial numbers for the players who play at the center." }, { "role": "assistant", "content": "SELECT \"no\" FROM \"fiba_euro_basket_2009_squads\" WHERE \"position\"='Center';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: What is the date of birth for basket baller called ido kozikaro" }, { "role": "assistant", "content": "SELECT MAX(\"year_born\") FROM \"fiba_euro_basket_2009_squads\" WHERE \"player\"='Ido Kozikaro';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: How many positions are available for players who are 6' 07\"?" }, { "role": "assistant", "content": "SELECT COUNT(\"position\") FROM \"fiba_euro_basket_2009_squads\" WHERE \"height_f\"='6'' 07\\\"';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: How tall is the basket ball player lior eliyahu in meters?" }, { "role": "assistant", "content": "SELECT \"height_m\" FROM \"fiba_euro_basket_2009_squads\" WHERE \"player\"='Lior Eliyahu';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"averages\" (\n \"rank_by_average\" real,\n \"place\" real,\n \"couple\" text,\n \"total_points_earned\" real,\n \"number_of_dances\" real,\n \"average\" text\n);\n\nQuestion: What was the average score for the couple that had 4 dances?" }, { "role": "assistant", "content": "SELECT \"average\" FROM \"averages\" WHERE \"number_of_dances\"=4;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"averages\" (\n \"rank_by_average\" real,\n \"place\" real,\n \"couple\" text,\n \"total_points_earned\" real,\n \"number_of_dances\" real,\n \"average\" text\n);\n\nQuestion: How many averages were listed for the couple who had 12 dances?" }, { "role": "assistant", "content": "SELECT COUNT(\"average\") FROM \"averages\" WHERE \"number_of_dances\"=12;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"averages\" (\n \"rank_by_average\" real,\n \"place\" real,\n \"couple\" text,\n \"total_points_earned\" real,\n \"number_of_dances\" real,\n \"average\" text\n);\n\nQuestion: How many total points were earned from the couple that averaged 29.0 points?" }, { "role": "assistant", "content": "SELECT MAX(\"total_points_earned\") FROM \"averages\" WHERE \"average\"='29.0';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_23667534_1\" (\n \"episode_title\" text,\n \"song_s_title\" text,\n \"writer\" text,\n \"singer_s\" text,\n \"album_s\" text\n);\n\nQuestion: What album was the song It's going so badly on?" }, { "role": "assistant", "content": "SELECT \"album_s\" FROM \"table1_23667534_1\" WHERE \"song_s_title\"='It''s Going So Badly';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_23667534_1\" (\n \"episode_title\" text,\n \"song_s_title\" text,\n \"writer\" text,\n \"singer_s\" text,\n \"album_s\" text\n);\n\nQuestion: What album was the song My Chariot on?" }, { "role": "assistant", "content": "SELECT \"album_s\" FROM \"table1_23667534_1\" WHERE \"song_s_title\"='My Chariot';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_23667534_1\" (\n \"episode_title\" text,\n \"song_s_title\" text,\n \"writer\" text,\n \"singer_s\" text,\n \"album_s\" text\n);\n\nQuestion: Who sand He's Bigfoot?" }, { "role": "assistant", "content": "SELECT \"singer_s\" FROM \"table1_23667534_1\" WHERE \"song_s_title\"='He''s Bigfoot';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_23667534_1\" (\n \"episode_title\" text,\n \"song_s_title\" text,\n \"writer\" text,\n \"singer_s\" text,\n \"album_s\" text\n);\n\nQuestion: What album was the song Shimmy Jimmy from the episode titled Toy to the world on?" }, { "role": "assistant", "content": "SELECT \"album_s\" FROM \"table1_23667534_1\" WHERE \"episode_title\"='Toy to the World' AND \"song_s_title\"='Shimmy Jimmy';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: which players have a height of 2.07m? " }, { "role": "assistant", "content": "SELECT \"player\" FROM \"fiba_euro_basket_2009_squads\" WHERE \"height_m\"='2.07';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: Which clubs have players with height 2.14m?" }, { "role": "assistant", "content": "SELECT \"current_club\" FROM \"fiba_euro_basket_2009_squads\" WHERE \"height_m\"='2.14';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: Which players were born in 1983 and play as forward position?" }, { "role": "assistant", "content": "SELECT \"player\" FROM \"fiba_euro_basket_2009_squads\" WHERE \"year_born\"=1983 AND \"position\"='Forward';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: What is every current club for the player Art\u016brs \u0160t\u0101lbergs?" }, { "role": "assistant", "content": "SELECT \"current_club\" FROM \"fiba_euro_basket_2009_squads\" WHERE \"player\"='Art\u016brs \u0160t\u0101lbergs';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: How many players have a height of 2.07?" }, { "role": "assistant", "content": "SELECT COUNT(\"player\") FROM \"fiba_euro_basket_2009_squads\" WHERE \"height_m\"='2.07';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: What is the latest year born when the current club is Barons LMT?" }, { "role": "assistant", "content": "SELECT MAX(\"year_born\") FROM \"fiba_euro_basket_2009_squads\" WHERE \"current_club\"='Barons LMT';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: How many current clubs have the player Aigars Vitols?" }, { "role": "assistant", "content": "SELECT COUNT(\"current_club\") FROM \"fiba_euro_basket_2009_squads\" WHERE \"player\"='Aigars Vitols';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: What is every year born for height of 1.88?" }, { "role": "assistant", "content": "SELECT \"year_born\" FROM \"fiba_euro_basket_2009_squads\" WHERE \"height_m\"='1.88';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fiba_euro_basket_2009_squads\" (\n \"no\" real,\n \"player\" text,\n \"height_m\" text,\n \"height_f\" text,\n \"position\" text,\n \"year_born\" real,\n \"current_club\" text\n);\n\nQuestion: What is every number when the player is Aigars Vitols?" }, { "role": "assistant", "content": "SELECT \"no\" FROM \"fiba_euro_basket_2009_squads\" WHERE \"player\"='Aigars Vitols';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"enrollment\" (\n \"year\" text,\n \"district_wide\" real,\n \"high_schools\" real,\n \"middle_schools\" real,\n \"elementary_schools\" real,\n \"other_programs_adjustments\" real\n);\n\nQuestion: Name the most high schools for 31851" }, { "role": "assistant", "content": "SELECT MAX(\"high_schools\") FROM \"enrollment\" WHERE \"district_wide\"=31851;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"enrollment\" (\n \"year\" text,\n \"district_wide\" real,\n \"high_schools\" real,\n \"middle_schools\" real,\n \"elementary_schools\" real,\n \"other_programs_adjustments\" real\n);\n\nQuestion: Name the most district wide for 1639 other programs" }, { "role": "assistant", "content": "SELECT MAX(\"district_wide\") FROM \"enrollment\" WHERE \"other_programs_adjustments\"=1639;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"enrollment\" (\n \"year\" text,\n \"district_wide\" real,\n \"high_schools\" real,\n \"middle_schools\" real,\n \"elementary_schools\" real,\n \"other_programs_adjustments\" real\n);\n\nQuestion: Name the total number of elementary schools for 31851" }, { "role": "assistant", "content": "SELECT COUNT(\"elementary_schools\") FROM \"enrollment\" WHERE \"district_wide\"=31851;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"enrollment\" (\n \"year\" text,\n \"district_wide\" real,\n \"high_schools\" real,\n \"middle_schools\" real,\n \"elementary_schools\" real,\n \"other_programs_adjustments\" real\n);\n\nQuestion: Name the most middle schools for 2005-2006" }, { "role": "assistant", "content": "SELECT MAX(\"middle_schools\") FROM \"enrollment\" WHERE \"year\"='2005-2006';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"average_polling\" (\n \"party\" text,\n \"result_parliam_election_2005\" text,\n \"result_county_elections_2007\" text,\n \"aug_2008\" text,\n \"sep_2008\" text,\n \"oct_2008\" text,\n \"nov_2008\" text,\n \"dec_2008\" text,\n \"jan_2009\" text,\n \"feb_2009\" text,\n \"mar_2009\" text,\n \"apr_2009\" text,\n \"may_2009\" text,\n \"jun_2009\" text,\n \"jul_2009\" text,\n \"aug_2009\" text\n);\n\nQuestion: If the polling average in July 2009 was 7.2%, what was it in May 2009?" }, { "role": "assistant", "content": "SELECT \"may_2009\" FROM \"average_polling\" WHERE \"jul_2009\"='7.2%';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"average_polling\" (\n \"party\" text,\n \"result_parliam_election_2005\" text,\n \"result_county_elections_2007\" text,\n \"aug_2008\" text,\n \"sep_2008\" text,\n \"oct_2008\" text,\n \"nov_2008\" text,\n \"dec_2008\" text,\n \"jan_2009\" text,\n \"feb_2009\" text,\n \"mar_2009\" text,\n \"apr_2009\" text,\n \"may_2009\" text,\n \"jun_2009\" text,\n \"jul_2009\" text,\n \"aug_2009\" text\n);\n\nQuestion: What was the polling average in Aug 2009 when is was 5.0% in Sep 2009?" }, { "role": "assistant", "content": "SELECT \"aug_2008\" FROM \"average_polling\" WHERE \"sep_2008\"='5.0%';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"average_polling\" (\n \"party\" text,\n \"result_parliam_election_2005\" text,\n \"result_county_elections_2007\" text,\n \"aug_2008\" text,\n \"sep_2008\" text,\n \"oct_2008\" text,\n \"nov_2008\" text,\n \"dec_2008\" text,\n \"jan_2009\" text,\n \"feb_2009\" text,\n \"mar_2009\" text,\n \"apr_2009\" text,\n \"may_2009\" text,\n \"jun_2009\" text,\n \"jul_2009\" text,\n \"aug_2009\" text\n);\n\nQuestion: How many polling percentages were there in October 2008 when is was 30.8% in Aug 2008?" }, { "role": "assistant", "content": "SELECT COUNT(\"oct_2008\") FROM \"average_polling\" WHERE \"aug_2008\"='30.8%';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"average_polling\" (\n \"party\" text,\n \"result_parliam_election_2005\" text,\n \"result_county_elections_2007\" text,\n \"aug_2008\" text,\n \"sep_2008\" text,\n \"oct_2008\" text,\n \"nov_2008\" text,\n \"dec_2008\" text,\n \"jan_2009\" text,\n \"feb_2009\" text,\n \"mar_2009\" text,\n \"apr_2009\" text,\n \"may_2009\" text,\n \"jun_2009\" text,\n \"jul_2009\" text,\n \"aug_2009\" text\n);\n\nQuestion: Name the party/s when the polling percentage was 6.3% in Dec 2008." }, { "role": "assistant", "content": "SELECT \"party\" FROM \"average_polling\" WHERE \"dec_2008\"='6.3%';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"average_polling\" (\n \"party\" text,\n \"result_parliam_election_2005\" text,\n \"result_county_elections_2007\" text,\n \"aug_2008\" text,\n \"sep_2008\" text,\n \"oct_2008\" text,\n \"nov_2008\" text,\n \"dec_2008\" text,\n \"jan_2009\" text,\n \"feb_2009\" text,\n \"mar_2009\" text,\n \"apr_2009\" text,\n \"may_2009\" text,\n \"jun_2009\" text,\n \"jul_2009\" text,\n \"aug_2009\" text\n);\n\nQuestion: What was the polling percentage in Jul 2009 when the Parliament Election result of 2005 was 6.5%?" }, { "role": "assistant", "content": "SELECT \"jul_2009\" FROM \"average_polling\" WHERE \"result_parliam_election_2005\"='6.5%';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"average_polling\" (\n \"party\" text,\n \"result_parliam_election_2005\" text,\n \"result_county_elections_2007\" text,\n \"aug_2008\" text,\n \"sep_2008\" text,\n \"oct_2008\" text,\n \"nov_2008\" text,\n \"dec_2008\" text,\n \"jan_2009\" text,\n \"feb_2009\" text,\n \"mar_2009\" text,\n \"apr_2009\" text,\n \"may_2009\" text,\n \"jun_2009\" text,\n \"jul_2009\" text,\n \"aug_2009\" text\n);\n\nQuestion: What was the polling percentage in Nov 2008 when it was 1.7% in Aug 2008?" }, { "role": "assistant", "content": "SELECT \"nov_2008\" FROM \"average_polling\" WHERE \"aug_2008\"='1.7%';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"average_polling\" (\n \"party\" text,\n \"week_32\" text,\n \"week_33\" text,\n \"week_34\" text,\n \"week_35\" text,\n \"week_36\" text,\n \"week_37\" text\n);\n\nQuestion: What is the week 32 result when week 33 is 31.9%?" }, { "role": "assistant", "content": "SELECT \"week_32\" FROM \"average_polling\" WHERE \"week_33\"='31.9%';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"average_polling\" (\n \"party\" text,\n \"week_32\" text,\n \"week_33\" text,\n \"week_34\" text,\n \"week_35\" text,\n \"week_36\" text,\n \"week_37\" text\n);\n\nQuestion: List all week 37 results when week 33 is 14.3%." }, { "role": "assistant", "content": "SELECT \"week_37\" FROM \"average_polling\" WHERE \"week_33\"='14.3%';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"average_polling\" (\n \"party\" text,\n \"week_32\" text,\n \"week_33\" text,\n \"week_34\" text,\n \"week_35\" text,\n \"week_36\" text,\n \"week_37\" text\n);\n\nQuestion: List the full amount of week 36 results when week 32 is 13.2%." }, { "role": "assistant", "content": "SELECT COUNT(\"week_36\") FROM \"average_polling\" WHERE \"week_32\"='13.2%';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_23685890_2\" (\n \"local_government_area\" text,\n \"type\" text,\n \"major_town\" text,\n \"land_area_km\" text,\n \"pop_2006\" real,\n \"density_km_2\" real,\n \"towns\" real,\n \"est\" real\n);\n\nQuestion: On what year was the local government area with a surface of 4563 square kilometers established?" }, { "role": "assistant", "content": "SELECT \"est\" FROM \"table1_23685890_2\" WHERE \"land_area_km\"='4563';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_23685890_2\" (\n \"local_government_area\" text,\n \"type\" text,\n \"major_town\" text,\n \"land_area_km\" text,\n \"pop_2006\" real,\n \"density_km_2\" real,\n \"towns\" real,\n \"est\" real\n);\n\nQuestion: Which major town is located within the Outback Areas Community Development Trust?" }, { "role": "assistant", "content": "SELECT \"major_town\" FROM \"table1_23685890_2\" WHERE \"local_government_area\"='Outback Areas Community Development Trust';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_23685890_2\" (\n \"local_government_area\" text,\n \"type\" text,\n \"major_town\" text,\n \"land_area_km\" text,\n \"pop_2006\" real,\n \"density_km_2\" real,\n \"towns\" real,\n \"est\" real\n);\n\nQuestion: How many towns exist on the government area with a surface of 110 square kilometers?" }, { "role": "assistant", "content": "SELECT MIN(\"towns\") FROM \"table1_23685890_2\" WHERE \"land_area_km\"='110';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_23685890_2\" (\n \"local_government_area\" text,\n \"type\" text,\n \"major_town\" text,\n \"land_area_km\" text,\n \"pop_2006\" real,\n \"density_km_2\" real,\n \"towns\" real,\n \"est\" real\n);\n\nQuestion: What type of local government area is Yalata?" }, { "role": "assistant", "content": "SELECT \"type\" FROM \"table1_23685890_2\" WHERE \"local_government_area\"='Yalata';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_23685890_2\" (\n \"local_government_area\" text,\n \"type\" text,\n \"major_town\" text,\n \"land_area_km\" text,\n \"pop_2006\" real,\n \"density_km_2\" real,\n \"towns\" real,\n \"est\" real\n);\n\nQuestion: What was the 2006 population count of the local government area where Coober Pedy is located?" }, { "role": "assistant", "content": "SELECT \"pop_2006\" FROM \"table1_23685890_2\" WHERE \"major_town\"='Coober Pedy';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"schedule\" (\n \"week\" real,\n \"date\" text,\n \"opponent\" text,\n \"location\" text,\n \"final_score\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: During what week was the game attended by 20114 people?" }, { "role": "assistant", "content": "SELECT MAX(\"week\") FROM \"schedule\" WHERE \"attendance\"=20114;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"schedule\" (\n \"week\" real,\n \"date\" text,\n \"opponent\" text,\n \"location\" text,\n \"final_score\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What was the record in game played on July 28?" }, { "role": "assistant", "content": "SELECT \"record\" FROM \"schedule\" WHERE \"date\"='July 28';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"schedule\" (\n \"week\" real,\n \"date\" text,\n \"opponent\" text,\n \"location\" text,\n \"final_score\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What was the record in the game against Eskimos?" }, { "role": "assistant", "content": "SELECT \"record\" FROM \"schedule\" WHERE \"opponent\"='Eskimos';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2012\" (\n \"name\" text,\n \"starting_chip_count\" real,\n \"wsop_bracelets\" real,\n \"wsop_cashes\" real,\n \"wsop_earnings\" text,\n \"final_place\" text,\n \"prize\" text\n);\n\nQuestion: Whose WSOP earnings were $36,372? " }, { "role": "assistant", "content": "SELECT \"name\" FROM \"2012\" WHERE \"wsop_earnings\"='$36,372';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2012\" (\n \"name\" text,\n \"starting_chip_count\" real,\n \"wsop_bracelets\" real,\n \"wsop_cashes\" real,\n \"wsop_earnings\" text,\n \"final_place\" text,\n \"prize\" text\n);\n\nQuestion: The person who had 0 WSOP earnings had how man WSOP cashes?" }, { "role": "assistant", "content": "SELECT \"wsop_cashes\" FROM \"2012\" WHERE \"wsop_earnings\"='0';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2012\" (\n \"name\" text,\n \"starting_chip_count\" real,\n \"wsop_bracelets\" real,\n \"wsop_cashes\" real,\n \"wsop_earnings\" text,\n \"final_place\" text,\n \"prize\" text\n);\n\nQuestion: Who had 2 WSOP cashes and was 6th in final place?" }, { "role": "assistant", "content": "SELECT \"name\" FROM \"2012\" WHERE \"wsop_cashes\"=2 AND \"final_place\"='6th';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2012\" (\n \"name\" text,\n \"starting_chip_count\" real,\n \"wsop_bracelets\" real,\n \"wsop_cashes\" real,\n \"wsop_earnings\" text,\n \"final_place\" text,\n \"prize\" text\n);\n\nQuestion: What is the smallest amount of WSOP bracelets anyone had?" }, { "role": "assistant", "content": "SELECT MIN(\"wsop_bracelets\") FROM \"2012\";" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2012\" (\n \"name\" text,\n \"starting_chip_count\" real,\n \"wsop_bracelets\" real,\n \"wsop_cashes\" real,\n \"wsop_earnings\" text,\n \"final_place\" text,\n \"prize\" text\n);\n\nQuestion: The person who had $126,796 WSOP earnings had how many WSOP cashes? " }, { "role": "assistant", "content": "SELECT \"wsop_cashes\" FROM \"2012\" WHERE \"wsop_earnings\"='$126,796';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_237036_2\" (\n \"level\" text,\n \"luma_samples_s\" real,\n \"macroblocks_s\" real,\n \"luma_samples\" real,\n \"macroblocks\" real,\n \"baseline_extended_and_main_profiles\" real,\n \"high_profile\" real,\n \"high_10_profile\" real,\n \"examples_for_high_resolution_highest_frame_rate_max_stored_frames_toggle_additional_details\" text\n);\n\nQuestion: What is the high 10 profile number when the high profile is 80?" }, { "role": "assistant", "content": "SELECT MAX(\"high_10_profile\") FROM \"table1_237036_2\" WHERE \"high_profile\"=80;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_237036_2\" (\n \"level\" text,\n \"luma_samples_s\" real,\n \"macroblocks_s\" real,\n \"luma_samples\" real,\n \"macroblocks\" real,\n \"baseline_extended_and_main_profiles\" real,\n \"high_profile\" real,\n \"high_10_profile\" real,\n \"examples_for_high_resolution_highest_frame_rate_max_stored_frames_toggle_additional_details\" text\n);\n\nQuestion: What is the baseline extended and main profiles when level is 1.3?" }, { "role": "assistant", "content": "SELECT MIN(\"baseline_extended_and_main_profiles\") FROM \"table1_237036_2\" WHERE \"level\"='1.3';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_237036_2\" (\n \"level\" text,\n \"luma_samples_s\" real,\n \"macroblocks_s\" real,\n \"luma_samples\" real,\n \"macroblocks\" real,\n \"baseline_extended_and_main_profiles\" real,\n \"high_profile\" real,\n \"high_10_profile\" real,\n \"examples_for_high_resolution_highest_frame_rate_max_stored_frames_toggle_additional_details\" text\n);\n\nQuestion: What level has 11880 macroblocks and high 10 profile is 6000?" }, { "role": "assistant", "content": "SELECT \"level\" FROM \"table1_237036_2\" WHERE \"macroblocks_s\"=11880 AND \"high_10_profile\"=6000;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_237036_2\" (\n \"level\" text,\n \"luma_samples_s\" real,\n \"macroblocks_s\" real,\n \"luma_samples\" real,\n \"macroblocks\" real,\n \"baseline_extended_and_main_profiles\" real,\n \"high_profile\" real,\n \"high_10_profile\" real,\n \"examples_for_high_resolution_highest_frame_rate_max_stored_frames_toggle_additional_details\" text\n);\n\nQuestion: What are the luma samples at level 1.3?" }, { "role": "assistant", "content": "SELECT \"luma_samples_s\" FROM \"table1_237036_2\" WHERE \"level\"='1.3';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_237036_2\" (\n \"level\" text,\n \"luma_samples_s\" real,\n \"macroblocks_s\" real,\n \"luma_samples\" real,\n \"macroblocks\" real,\n \"baseline_extended_and_main_profiles\" real,\n \"high_profile\" real,\n \"high_10_profile\" real,\n \"examples_for_high_resolution_highest_frame_rate_max_stored_frames_toggle_additional_details\" text\n);\n\nQuestion: What is the high 10 profile when high profile is 160?" }, { "role": "assistant", "content": "SELECT \"high_10_profile\" FROM \"table1_237036_2\" WHERE \"high_profile\"=160;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_23705843_1\" (\n \"episode\" text,\n \"director\" text,\n \"writer\" text,\n \"original_air_date\" text,\n \"ratings_millions\" text\n);\n\nQuestion: What is the original air date if the ratings is 1.92 million?" }, { "role": "assistant", "content": "SELECT \"original_air_date\" FROM \"table1_23705843_1\" WHERE \"ratings_millions\"='1.92';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_23705843_1\" (\n \"episode\" text,\n \"director\" text,\n \"writer\" text,\n \"original_air_date\" text,\n \"ratings_millions\" text\n);\n\nQuestion: What is the name of the writer when the ratings was 2.61 million?" }, { "role": "assistant", "content": "SELECT \"writer\" FROM \"table1_23705843_1\" WHERE \"ratings_millions\"='2.61';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_2370579_1\" (\n \"episode_num\" real,\n \"prod_num\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"originalairdate\" text,\n \"filmed\" text\n);\n\nQuestion: What date did the episode \"the killing (part two)\" originally air?" }, { "role": "assistant", "content": "SELECT \"originalairdate\" FROM \"table1_2370579_1\" WHERE \"title\"='\\\"The Killing (part two)\\\"';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_2370579_1\" (\n \"episode_num\" real,\n \"prod_num\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"originalairdate\" text,\n \"filmed\" text\n);\n\nQuestion: Who directed the episode written by Tony O'Grady (pseudonym of brian clemens)?" }, { "role": "assistant", "content": "SELECT \"directed_by\" FROM \"table1_2370579_1\" WHERE \"written_by\"='Tony O''Grady (pseudonym of Brian Clemens)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_2370579_1\" (\n \"episode_num\" real,\n \"prod_num\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"originalairdate\" text,\n \"filmed\" text\n);\n\nQuestion: What is the production number for episode 23?" }, { "role": "assistant", "content": "SELECT MIN(\"prod_num\") FROM \"table1_2370579_1\" WHERE \"episode_num\"=23;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_2370579_1\" (\n \"episode_num\" real,\n \"prod_num\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"originalairdate\" text,\n \"filmed\" text\n);\n\nQuestion: What month and year was \"storm warning (part one)\" filmed?" }, { "role": "assistant", "content": "SELECT \"filmed\" FROM \"table1_2370579_1\" WHERE \"title\"='\\\"Storm Warning (part one)\\\"';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"future_tense\" (\n \"aromanian_gramustean_farshirot\" text,\n \"romanian_archaic\" text,\n \"romanian_colloquial\" text,\n \"romanian_modern\" text,\n \"english\" text\n);\n\nQuestion: What is the colloquial translation of (s)he will sing? " }, { "role": "assistant", "content": "SELECT \"romanian_colloquial\" FROM \"future_tense\" WHERE \"english\"='(s)he will sing';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"bowl_games\" (\n \"bowl_game\" text,\n \"date\" text,\n \"stadium\" text,\n \"city\" text,\n \"television\" text,\n \"matchup_results\" text,\n \"attendance\" real,\n \"payout_us\" text\n);\n\nQuestion: What was the date of the game played in El Paso, Texas?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"bowl_games\" WHERE \"city\"='El Paso, Texas';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"bowl_games\" (\n \"bowl_game\" text,\n \"date\" text,\n \"stadium\" text,\n \"city\" text,\n \"television\" text,\n \"matchup_results\" text,\n \"attendance\" real,\n \"payout_us\" text\n);\n\nQuestion: How many different matchup/results appear in San Diego, California?" }, { "role": "assistant", "content": "SELECT COUNT(\"matchup_results\") FROM \"bowl_games\" WHERE \"city\"='San Diego, California';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"bowl_games\" (\n \"bowl_game\" text,\n \"date\" text,\n \"stadium\" text,\n \"city\" text,\n \"television\" text,\n \"matchup_results\" text,\n \"attendance\" real,\n \"payout_us\" text\n);\n\nQuestion: How many different items appear in the television column when the results where Iowa State 14, Minnesota 13?" }, { "role": "assistant", "content": "SELECT COUNT(\"television\") FROM \"bowl_games\" WHERE \"matchup_results\"='Iowa State 14, Minnesota 13';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"bowl_games\" (\n \"bowl_game\" text,\n \"date\" text,\n \"stadium\" text,\n \"city\" text,\n \"television\" text,\n \"matchup_results\" text,\n \"attendance\" real,\n \"payout_us\" text\n);\n\nQuestion: How many different items appear in he attendance column at Sun Devil Stadium?" }, { "role": "assistant", "content": "SELECT COUNT(\"attendance\") FROM \"bowl_games\" WHERE \"stadium\"='Sun Devil Stadium';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"bowl_games\" (\n \"bowl_game\" text,\n \"date\" text,\n \"stadium\" text,\n \"city\" text,\n \"television\" text,\n \"matchup_results\" text,\n \"attendance\" real,\n \"payout_us\" text\n);\n\nQuestion: In what bowl game was the result Oklahoma 31, Stanford 27?" }, { "role": "assistant", "content": "SELECT \"bowl_game\" FROM \"bowl_games\" WHERE \"matchup_results\"='Oklahoma 31, Stanford 27';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"bowl_games\" (\n \"bowl_game\" text,\n \"date\" text,\n \"stadium\" text,\n \"city\" text,\n \"television\" text,\n \"matchup_results\" text,\n \"attendance\" real,\n \"payout_us\" text\n);\n\nQuestion: What was the television that was dated December 28, 2009?" }, { "role": "assistant", "content": "SELECT \"television\" FROM \"bowl_games\" WHERE \"date\"='December 28, 2009';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"manufacturer_s_worldwide_ranking\" (\n \"rank\" real,\n \"company_name\" text,\n \"2008_rank\" text,\n \"2009_revenue\" text,\n \"north_american_brands\" text,\n \"world_headquarters\" text,\n \"country\" text\n);\n\nQuestion: Which rank has a 2009 revenue of $296,000,000?" }, { "role": "assistant", "content": "SELECT \"rank\" FROM \"manufacturer_s_worldwide_ranking\" WHERE \"2009_revenue\"='$296,000,000';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"manufacturer_s_worldwide_ranking\" (\n \"rank\" real,\n \"company_name\" text,\n \"2008_rank\" text,\n \"2009_revenue\" text,\n \"north_american_brands\" text,\n \"world_headquarters\" text,\n \"country\" text\n);\n\nQuestion: Which country has doosan infracore as then company name?" }, { "role": "assistant", "content": "SELECT \"country\" FROM \"manufacturer_s_worldwide_ranking\" WHERE \"company_name\"='Doosan Infracore';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"manufacturer_s_worldwide_ranking\" (\n \"rank\" real,\n \"company_name\" text,\n \"2008_rank\" text,\n \"2009_revenue\" text,\n \"north_american_brands\" text,\n \"world_headquarters\" text,\n \"country\" text\n);\n\nQuestion: How many north american brands have world headquarters in sagamihara?" }, { "role": "assistant", "content": "SELECT COUNT(\"north_american_brands\") FROM \"manufacturer_s_worldwide_ranking\" WHERE \"world_headquarters\"='Sagamihara';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"manufacturer_s_worldwide_ranking\" (\n \"rank\" real,\n \"company_name\" text,\n \"2008_rank\" text,\n \"2009_revenue\" text,\n \"north_american_brands\" text,\n \"world_headquarters\" text,\n \"country\" text\n);\n\nQuestion: Which company name has headquarters in nagaokakyo, kyoto?" }, { "role": "assistant", "content": "SELECT \"company_name\" FROM \"manufacturer_s_worldwide_ranking\" WHERE \"world_headquarters\"='Nagaokakyo, Kyoto';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"manufacturer_s_worldwide_ranking\" (\n \"rank\" real,\n \"company_name\" text,\n \"2008_rank\" text,\n \"2009_revenue\" text,\n \"north_american_brands\" text,\n \"world_headquarters\" text,\n \"country\" text\n);\n\nQuestion: Which company name has a 2008 rank of n/a?" }, { "role": "assistant", "content": "SELECT COUNT(\"company_name\") FROM \"manufacturer_s_worldwide_ranking\" WHERE \"2008_rank\"='N/A';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"engines\" (\n \"vehicle_code\" text,\n \"bore_mm\" text,\n \"stroke_mm\" text,\n \"capacity_cm_3\" real,\n \"compression_ratio\" text,\n \"torque_n_m\" real,\n \"power_hp\" real\n);\n\nQuestion: what is the bore where the vehicle code is t214?" }, { "role": "assistant", "content": "SELECT \"bore_mm\" FROM \"engines\" WHERE \"vehicle_code\"='T214';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"engines\" (\n \"vehicle_code\" text,\n \"bore_mm\" text,\n \"stroke_mm\" text,\n \"capacity_cm_3\" real,\n \"compression_ratio\" text,\n \"torque_n_m\" real,\n \"power_hp\" real\n);\n\nQuestion: what is the compression ratio whre the torque is 208?" }, { "role": "assistant", "content": "SELECT \"compression_ratio\" FROM \"engines\" WHERE \"torque_n_m\"=208;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"engines\" (\n \"vehicle_code\" text,\n \"bore_mm\" text,\n \"stroke_mm\" text,\n \"capacity_cm_3\" real,\n \"compression_ratio\" text,\n \"torque_n_m\" real,\n \"power_hp\" real\n);\n\nQuestion: what is the vehicle code where the bore is 79.4?" }, { "role": "assistant", "content": "SELECT \"vehicle_code\" FROM \"engines\" WHERE \"bore_mm\"='79.4';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"engines\" (\n \"vehicle_code\" text,\n \"bore_mm\" text,\n \"stroke_mm\" text,\n \"capacity_cm_3\" real,\n \"compression_ratio\" text,\n \"torque_n_m\" real,\n \"power_hp\" real\n);\n\nQuestion: what is the stroke where the vehicle code is t211?" }, { "role": "assistant", "content": "SELECT \"stroke_mm\" FROM \"engines\" WHERE \"vehicle_code\"='T211';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_1_2010\" (\n \"no\" real,\n \"episode\" text,\n \"rating\" text,\n \"share\" real,\n \"rating_share_18_49\" text,\n \"viewers_millions\" text,\n \"rank_timeslot\" real,\n \"rank_night\" real\n);\n\nQuestion: What was the rating/share for 18-49 for the episode that had 5.90 million viewers? " }, { "role": "assistant", "content": "SELECT \"rating_share_18_49\" FROM \"season_1_2010\" WHERE \"viewers_millions\"='5.90';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_1_2010\" (\n \"no\" real,\n \"episode\" text,\n \"rating\" text,\n \"share\" real,\n \"rating_share_18_49\" text,\n \"viewers_millions\" text,\n \"rank_timeslot\" real,\n \"rank_night\" real\n);\n\nQuestion: What was the title of episode 3?" }, { "role": "assistant", "content": "SELECT \"episode\" FROM \"season_1_2010\" WHERE \"no\"=3;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_1_2010\" (\n \"no\" real,\n \"episode\" text,\n \"rating\" text,\n \"share\" real,\n \"rating_share_18_49\" text,\n \"viewers_millions\" text,\n \"rank_timeslot\" real,\n \"rank_night\" real\n);\n\nQuestion: What number episode had a rating of 4.7?" }, { "role": "assistant", "content": "SELECT MIN(\"no\") FROM \"season_1_2010\" WHERE \"rating\"='4.7';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_1_2010\" (\n \"no\" real,\n \"episode\" text,\n \"rating\" text,\n \"share\" real,\n \"rating_share_18_49\" text,\n \"viewers_millions\" text,\n \"rank_timeslot\" real,\n \"rank_night\" real\n);\n\nQuestion: What was the share for the \"Lisa Kudrow\" episode? " }, { "role": "assistant", "content": "SELECT MIN(\"share\") FROM \"season_1_2010\" WHERE \"episode\"='\\\"Lisa Kudrow\\\"';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_1_2010\" (\n \"no\" real,\n \"episode\" text,\n \"rating\" text,\n \"share\" real,\n \"rating_share_18_49\" text,\n \"viewers_millions\" text,\n \"rank_timeslot\" real,\n \"rank_night\" real\n);\n\nQuestion: What was the rating for the episode that had 5.90 million viewers? " }, { "role": "assistant", "content": "SELECT \"rating\" FROM \"season_1_2010\" WHERE \"viewers_millions\"='5.90';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"season_1_2010\" (\n \"no\" real,\n \"episode\" text,\n \"rating\" text,\n \"share\" real,\n \"rating_share_18_49\" text,\n \"viewers_millions\" text,\n \"rank_timeslot\" real,\n \"rank_night\" real\n);\n\nQuestion: What number episode had a 4.2 rating? " }, { "role": "assistant", "content": "SELECT MIN(\"no\") FROM \"season_1_2010\" WHERE \"rating\"='4.2';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"by_year\" (\n \"year\" real,\n \"winner_number_of_titles\" text,\n \"runners_up\" text,\n \"top_team_in_regular_season_points\" text,\n \"top_scorer_points\" text,\n \"winning_coach\" text\n);\n\nQuestion: What is the winning coach total number if the top team in regular season (points) is the Kansas City Spurs (110 points)?" }, { "role": "assistant", "content": "SELECT COUNT(\"winning_coach\") FROM \"by_year\" WHERE \"top_team_in_regular_season_points\"='Kansas City Spurs (110 points)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"by_year\" (\n \"year\" real,\n \"winner_number_of_titles\" text,\n \"runners_up\" text,\n \"top_team_in_regular_season_points\" text,\n \"top_scorer_points\" text,\n \"winning_coach\" text\n);\n\nQuestion: If the top team in regular season (points) is the New York Cosmos (200 points), what is the winner (number of titles)?" }, { "role": "assistant", "content": "SELECT \"winner_number_of_titles\" FROM \"by_year\" WHERE \"top_team_in_regular_season_points\"='New York Cosmos (200 points)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"by_year\" (\n \"year\" real,\n \"winner_number_of_titles\" text,\n \"runners_up\" text,\n \"top_team_in_regular_season_points\" text,\n \"top_scorer_points\" text,\n \"winning_coach\" text\n);\n\nQuestion: If the runner-up is the Fort Lauderdale Strikers, what is the winner (number of titles)?" }, { "role": "assistant", "content": "SELECT \"winner_number_of_titles\" FROM \"by_year\" WHERE \"runners_up\"='Fort Lauderdale Strikers';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_23777640_1\" (\n \"administrative_district\" text,\n \"ds_divisions\" real,\n \"gn_divisions\" real,\n \"total_area_km_2\" real,\n \"land_area_km_2\" real,\n \"sri_lankan_tamil\" real,\n \"sri_lankan_moors\" real,\n \"sinhalese\" real,\n \"indian_tamil\" real,\n \"other\" real,\n \"total\" real,\n \"population_density_km_2\" real\n);\n\nQuestion: How many figures for Other in the district where the GN division is 95?" }, { "role": "assistant", "content": "SELECT COUNT(\"other\") FROM \"table1_23777640_1\" WHERE \"gn_divisions\"=95;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"in_operation\" (\n \"rank\" real,\n \"operators_name\" text,\n \"technology\" text,\n \"subscribers_in_millions\" text,\n \"ownership\" text,\n \"market_share\" text\n);\n\nQuestion: What was the market share of the operator whose technology is CDMA EVDO GSM EDGE HSPA+?" }, { "role": "assistant", "content": "SELECT \"market_share\" FROM \"in_operation\" WHERE \"technology\"='CDMA EVDO GSM EDGE HSPA+';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"in_operation\" (\n \"rank\" real,\n \"operators_name\" text,\n \"technology\" text,\n \"subscribers_in_millions\" text,\n \"ownership\" text,\n \"market_share\" text\n);\n\nQuestion: What was the rank of operator whose technology is CDMA EVDO?" }, { "role": "assistant", "content": "SELECT MIN(\"rank\") FROM \"in_operation\" WHERE \"technology\"='CDMA EVDO';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_23793770_1\" (\n \"no_in_series\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"production_code\" real,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: What was the production code for the episode directed by Michael Morris?" }, { "role": "assistant", "content": "SELECT MIN(\"production_code\") FROM \"table1_23793770_1\" WHERE \"directed_by\"='Michael Morris';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_23793770_1\" (\n \"no_in_series\" real,\n \"title\" text,\n \"directed_by\" text,\n \"written_by\" text,\n \"original_air_date\" text,\n \"production_code\" real,\n \"u_s_viewers_millions\" text\n);\n\nQuestion: What is the title the episode directed by Allison Liddi-Brown?" }, { "role": "assistant", "content": "SELECT \"title\" FROM \"table1_23793770_1\" WHERE \"directed_by\"='Allison Liddi-Brown';" } ]