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 \"biggest_wins\" (\n \"margin\" real,\n \"score\" text,\n \"opponent\" text,\n \"venue\" text,\n \"year\" real\n);\n\nQuestion: Name the sum of year for penrith panthers opponent" }, { "role": "assistant", "content": "SELECT SUM(\"year\") FROM \"biggest_wins\" WHERE \"opponent\"='penrith panthers';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"biggest_wins\" (\n \"margin\" real,\n \"score\" text,\n \"opponent\" text,\n \"venue\" text,\n \"year\" real\n);\n\nQuestion: Name the opponent for 1996 at the mt smart stadium venue" }, { "role": "assistant", "content": "SELECT \"opponent\" FROM \"biggest_wins\" WHERE \"venue\"='mt smart stadium' AND \"year\"=1996;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"biggest_wins\" (\n \"margin\" real,\n \"score\" text,\n \"opponent\" text,\n \"venue\" text,\n \"year\" real\n);\n\nQuestion: Name the average year for 46 margin" }, { "role": "assistant", "content": "SELECT AVG(\"year\") FROM \"biggest_wins\" WHERE \"margin\"=46;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"biggest_wins\" (\n \"margin\" real,\n \"score\" text,\n \"opponent\" text,\n \"venue\" text,\n \"year\" real\n);\n\nQuestion: Name the margin for 2002" }, { "role": "assistant", "content": "SELECT \"margin\" FROM \"biggest_wins\" WHERE \"year\"=2002;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"past_winners\" (\n \"year\" real,\n \"men_s_singles\" text,\n \"women_s_singles\" text,\n \"women_s_doubles\" text,\n \"mixed_doubles\" text\n);\n\nQuestion: Who participated in the Mixed Doubles when Tracey Hallam participated in the Women's Singles?" }, { "role": "assistant", "content": "SELECT \"mixed_doubles\" FROM \"past_winners\" WHERE \"women_s_singles\"='tracey hallam';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"past_winners\" (\n \"year\" real,\n \"men_s_singles\" text,\n \"women_s_singles\" text,\n \"women_s_doubles\" text,\n \"mixed_doubles\" text\n);\n\nQuestion: Who participated in the Mixed Doubles when Simon Santoso participated in the Men's Singles after 2008?" }, { "role": "assistant", "content": "SELECT \"mixed_doubles\" FROM \"past_winners\" WHERE \"men_s_singles\"='simon santoso' AND \"year\">2008;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"private_schools\" (\n \"school\" text,\n \"grades\" text,\n \"affiliation\" text,\n \"student_body\" text,\n \"enrollment\" real\n);\n\nQuestion: Which Affiliation has an Enrollement larger than 502?" }, { "role": "assistant", "content": "SELECT \"affiliation\" FROM \"private_schools\" WHERE \"enrollment\">502;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"private_schools\" (\n \"school\" text,\n \"grades\" text,\n \"affiliation\" text,\n \"student_body\" text,\n \"enrollment\" real\n);\n\nQuestion: What School has an Enrollement smaller than 301?" }, { "role": "assistant", "content": "SELECT \"school\" FROM \"private_schools\" WHERE \"enrollment\"<301;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"private_schools\" (\n \"school\" text,\n \"grades\" text,\n \"affiliation\" text,\n \"student_body\" text,\n \"enrollment\" real\n);\n\nQuestion: Which Grades has an Enrollment larger htan 443 with a Student body of Co-ed?" }, { "role": "assistant", "content": "SELECT \"grades\" FROM \"private_schools\" WHERE \"enrollment\">443 AND \"student_body\"='co-ed';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"private_schools\" (\n \"school\" text,\n \"grades\" text,\n \"affiliation\" text,\n \"student_body\" text,\n \"enrollment\" real\n);\n\nQuestion: What's the Student Body with an Affiliation of Roman Catholic and has an Enrollment of 502?" }, { "role": "assistant", "content": "SELECT \"student_body\" FROM \"private_schools\" WHERE \"affiliation\"='roman catholic' AND \"enrollment\"=502;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"grand_tour_finishers\" (\n \"rider\" text,\n \"year\" real,\n \"final_position_giro\" real,\n \"final_position_tour\" real,\n \"final_position_vuelta\" real\n);\n\nQuestion: What is the average year that has a final Tour position of 54 and a final Vuelta position over 55?" }, { "role": "assistant", "content": "SELECT AVG(\"year\") FROM \"grand_tour_finishers\" WHERE \"final_position_tour\"=54 AND \"final_position_vuelta\">55;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"grand_tour_finishers\" (\n \"rider\" text,\n \"year\" real,\n \"final_position_giro\" real,\n \"final_position_tour\" real,\n \"final_position_vuelta\" real\n);\n\nQuestion: What is the final Vuelta position associated with a final Giro position over 39 and a final Tour position of 90?" }, { "role": "assistant", "content": "SELECT \"final_position_vuelta\" FROM \"grand_tour_finishers\" WHERE \"final_position_giro\">39 AND \"final_position_tour\"=90;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"grand_tour_finishers\" (\n \"rider\" text,\n \"year\" real,\n \"final_position_giro\" real,\n \"final_position_tour\" real,\n \"final_position_vuelta\" real\n);\n\nQuestion: How many Giro positions are associated with the year 1971 and Tour final positions over 50?" }, { "role": "assistant", "content": "SELECT COUNT(\"final_position_giro\") FROM \"grand_tour_finishers\" WHERE \"year\"=1971 AND \"final_position_tour\">50;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"250cc_classification\" (\n \"rider\" text,\n \"manufacturer\" text,\n \"laps\" real,\n \"time_retired\" text,\n \"grid\" real\n);\n\nQuestion: How many laps did the rider Alex Baldolini take?" }, { "role": "assistant", "content": "SELECT SUM(\"laps\") FROM \"250cc_classification\" WHERE \"rider\"='alex baldolini';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"250cc_classification\" (\n \"rider\" text,\n \"manufacturer\" text,\n \"laps\" real,\n \"time_retired\" text,\n \"grid\" real\n);\n\nQuestion: How many laps were completed in the time of +7.213 with a grid number larger than 7?" }, { "role": "assistant", "content": "SELECT COUNT(\"laps\") FROM \"250cc_classification\" WHERE \"time_retired\"='+7.213' AND \"grid\">7;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"250cc_classification\" (\n \"rider\" text,\n \"manufacturer\" text,\n \"laps\" real,\n \"time_retired\" text,\n \"grid\" real\n);\n\nQuestion: What is total number of laps for bikes manufactured by KTM with a time of +3.578 and a grid number larger than 4?" }, { "role": "assistant", "content": "SELECT COUNT(\"laps\") FROM \"250cc_classification\" WHERE \"manufacturer\"='ktm' AND \"time_retired\"='+3.578' AND \"grid\">4;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"atp_challenger_tour_and_itf_futures_doub\" (\n \"date\" text,\n \"tournament\" text,\n \"surface\" text,\n \"partner\" text,\n \"opponents\" text,\n \"score\" text\n);\n\nQuestion: What was the surface for the May 10, 2009 tournament?" }, { "role": "assistant", "content": "SELECT \"surface\" FROM \"atp_challenger_tour_and_itf_futures_doub\" WHERE \"date\"='may 10, 2009';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"24_hours_of_le_mans_results\" (\n \"year\" real,\n \"class\" text,\n \"tyres\" text,\n \"team\" text,\n \"co_drivers\" text,\n \"laps\" real,\n \"pos\" text,\n \"class_pos\" text\n);\n\nQuestion: Which co-driver has fewer than 282 laps and type P tyres?" }, { "role": "assistant", "content": "SELECT \"co_drivers\" FROM \"24_hours_of_le_mans_results\" WHERE \"laps\"<282 AND \"tyres\"='p';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"24_hours_of_le_mans_results\" (\n \"year\" real,\n \"class\" text,\n \"tyres\" text,\n \"team\" text,\n \"co_drivers\" text,\n \"laps\" real,\n \"pos\" text,\n \"class_pos\" text\n);\n\nQuestion: Which class more recent than 1988 has G tyres?" }, { "role": "assistant", "content": "SELECT \"class\" FROM \"24_hours_of_le_mans_results\" WHERE \"tyres\"='g' AND \"year\">1988;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"internationally_capped_players\" (\n \"player\" text,\n \"country\" text,\n \"caps\" real,\n \"goals\" text,\n \"years_active\" text,\n \"years_at_club\" text\n);\n\nQuestion: What is the greatest number of caps for Bruce Djite?" }, { "role": "assistant", "content": "SELECT MAX(\"caps\") FROM \"internationally_capped_players\" WHERE \"player\"='bruce djite';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"internationally_capped_players\" (\n \"player\" text,\n \"country\" text,\n \"caps\" real,\n \"goals\" text,\n \"years_active\" text,\n \"years_at_club\" text\n);\n\nQuestion: How many goals were scored by Eugene Galekovi\u0107?" }, { "role": "assistant", "content": "SELECT \"goals\" FROM \"internationally_capped_players\" WHERE \"player\"='eugene galekovi\u0107';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"internationally_capped_players\" (\n \"player\" text,\n \"country\" text,\n \"caps\" real,\n \"goals\" text,\n \"years_active\" text,\n \"years_at_club\" text\n);\n\nQuestion: How many goals were scored by players with more than 16 caps?" }, { "role": "assistant", "content": "SELECT \"goals\" FROM \"internationally_capped_players\" WHERE \"caps\">16;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"semifinal_2\" (\n \"rank\" real,\n \"lane\" real,\n \"name\" text,\n \"nationality\" text,\n \"time\" text\n);\n\nQuestion: What is the highest place of a swimmer from the Netherlands?" }, { "role": "assistant", "content": "SELECT MAX(\"rank\") FROM \"semifinal_2\" WHERE \"nationality\"='netherlands';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"waikato_district\" (\n \"name\" text,\n \"years\" text,\n \"gender\" text,\n \"area\" text,\n \"authority\" text,\n \"decile\" text,\n \"roll\" real\n);\n\nQuestion: Name the authority for te akau with roll less than 254 and decile of 8" }, { "role": "assistant", "content": "SELECT \"authority\" FROM \"waikato_district\" WHERE \"roll\"<254 AND \"decile\"='8' AND \"area\"='te akau';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"waikato_district\" (\n \"name\" text,\n \"years\" text,\n \"gender\" text,\n \"area\" text,\n \"authority\" text,\n \"decile\" text,\n \"roll\" real\n);\n\nQuestion: Tell me the name with decile of 6 and roll of 93" }, { "role": "assistant", "content": "SELECT \"name\" FROM \"waikato_district\" WHERE \"decile\"='6' AND \"roll\"=93;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"international_goals\" (\n \"goal\" real,\n \"date\" text,\n \"venue\" text,\n \"score\" text,\n \"result\" text,\n \"competition\" text\n);\n\nQuestion: What is the result of the match on January 26, 2006?" }, { "role": "assistant", "content": "SELECT \"result\" FROM \"international_goals\" WHERE \"date\"='january 26, 2006';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"specifications\" (\n \"model\" text,\n \"launch_year\" real,\n \"ram_mi_b\" real,\n \"rom_mi_b\" real,\n \"slots\" text,\n \"wi_fi\" text,\n \"bluetooth\" text\n);\n\nQuestion: What was the status of Bluetooth for the model that launched after 2004 with a ROM (MiB) of 128 and a Wifi of 802.11b?" }, { "role": "assistant", "content": "SELECT \"bluetooth\" FROM \"specifications\" WHERE \"launch_year\">2004 AND \"rom_mi_b\"=128 AND \"wi_fi\"='802.11b';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"specifications\" (\n \"model\" text,\n \"launch_year\" real,\n \"ram_mi_b\" real,\n \"rom_mi_b\" real,\n \"slots\" text,\n \"wi_fi\" text,\n \"bluetooth\" text\n);\n\nQuestion: What is the RAM (MiB) value for the X30 Mid-Range model?" }, { "role": "assistant", "content": "SELECT \"ram_mi_b\" FROM \"specifications\" WHERE \"model\"='x30 mid-range';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"season\" text,\n \"games\" real,\n \"lost\" real,\n \"tied\" text,\n \"points\" real,\n \"goals_for\" real,\n \"goals_against\" real,\n \"standing\" text\n);\n\nQuestion: How many points did the team with more than 68 games, 4 ties, and more than 272 goals against have?" }, { "role": "assistant", "content": "SELECT SUM(\"points\") FROM \"regular_season\" WHERE \"games\">68 AND \"tied\"='4' AND \"goals_against\">272;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"short_course_25_meter_pool\" (\n \"event\" text,\n \"time\" text,\n \"venue\" text,\n \"date\" text,\n \"notes\" text\n);\n\nQuestion: Which event had the time 45.74?" }, { "role": "assistant", "content": "SELECT \"event\" FROM \"short_course_25_meter_pool\" WHERE \"time\"='45.74';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"short_course_25_meter_pool\" (\n \"event\" text,\n \"time\" text,\n \"venue\" text,\n \"date\" text,\n \"notes\" text\n);\n\nQuestion: What was the time of December 15, 2010?" }, { "role": "assistant", "content": "SELECT \"time\" FROM \"short_course_25_meter_pool\" WHERE \"date\"='december 15, 2010';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"short_course_25_meter_pool\" (\n \"event\" text,\n \"time\" text,\n \"venue\" text,\n \"date\" text,\n \"notes\" text\n);\n\nQuestion: What were the notes for the time 45.74?" }, { "role": "assistant", "content": "SELECT \"notes\" FROM \"short_course_25_meter_pool\" WHERE \"time\"='45.74';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2008_squad_statistics\" (\n \"player\" text,\n \"position\" text,\n \"previous_club\" text,\n \"apps\" real,\n \"tries\" real,\n \"goals\" text,\n \"points\" real\n);\n\nQuestion: What Player has 23 Tries?" }, { "role": "assistant", "content": "SELECT \"player\" FROM \"2008_squad_statistics\" WHERE \"tries\"=23;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2008_squad_statistics\" (\n \"player\" text,\n \"position\" text,\n \"previous_club\" text,\n \"apps\" real,\n \"tries\" real,\n \"goals\" text,\n \"points\" real\n);\n\nQuestion: How many Goals did Matt Cook have?" }, { "role": "assistant", "content": "SELECT \"goals\" FROM \"2008_squad_statistics\" WHERE \"player\"='matt cook';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2008_squad_statistics\" (\n \"player\" text,\n \"position\" text,\n \"previous_club\" text,\n \"apps\" real,\n \"tries\" real,\n \"goals\" text,\n \"points\" real\n);\n\nQuestion: What Full Back Player has 0 Apps?" }, { "role": "assistant", "content": "SELECT \"player\" FROM \"2008_squad_statistics\" WHERE \"position\"='full back' AND \"apps\"=0;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2008_squad_statistics\" (\n \"player\" text,\n \"position\" text,\n \"previous_club\" text,\n \"apps\" real,\n \"tries\" real,\n \"goals\" text,\n \"points\" real\n);\n\nQuestion: With 0 Goals and less than 1 Tries, what is Matt James position?" }, { "role": "assistant", "content": "SELECT \"position\" FROM \"2008_squad_statistics\" WHERE \"goals\"='0' AND \"tries\"<1 AND \"player\"='matt james';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"january_secondary_phase\" (\n \"round\" real,\n \"name\" text,\n \"position\" text,\n \"school\" text,\n \"signed\" text\n);\n\nQuestion: What is the earliest round drafted for a University of Southern California player?" }, { "role": "assistant", "content": "SELECT MIN(\"round\") FROM \"january_secondary_phase\" WHERE \"school\"='university of southern california';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"january_secondary_phase\" (\n \"round\" real,\n \"name\" text,\n \"position\" text,\n \"school\" text,\n \"signed\" text\n);\n\nQuestion: What round drafted was the 1b and a Signed of no cardinals - 1969 june?" }, { "role": "assistant", "content": "SELECT COUNT(\"round\") FROM \"january_secondary_phase\" WHERE \"position\"='1b' AND \"signed\"='no cardinals - 1969 june';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"mixed_martial_arts_record\" (\n \"res\" text,\n \"record\" text,\n \"opponent\" text,\n \"method\" text,\n \"event\" text,\n \"round\" real,\n \"time\" text,\n \"location\" text\n);\n\nQuestion: Which event has an Opponent of akihiro gono, and a Method of decision?" }, { "role": "assistant", "content": "SELECT \"event\" FROM \"mixed_martial_arts_record\" WHERE \"opponent\"='akihiro gono' AND \"method\"='decision';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"mixed_martial_arts_record\" (\n \"res\" text,\n \"record\" text,\n \"opponent\" text,\n \"method\" text,\n \"event\" text,\n \"round\" real,\n \"time\" text,\n \"location\" text\n);\n\nQuestion: Which location has an Opponent of masanori suda?" }, { "role": "assistant", "content": "SELECT \"location\" FROM \"mixed_martial_arts_record\" WHERE \"opponent\"='masanori suda';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"mixed_martial_arts_record\" (\n \"res\" text,\n \"record\" text,\n \"opponent\" text,\n \"method\" text,\n \"event\" text,\n \"round\" real,\n \"time\" text,\n \"location\" text\n);\n\nQuestion: Which opponent has a Time of 1:34?" }, { "role": "assistant", "content": "SELECT \"opponent\" FROM \"mixed_martial_arts_record\" WHERE \"time\"='1:34';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"mixed_martial_arts_record\" (\n \"res\" text,\n \"record\" text,\n \"opponent\" text,\n \"method\" text,\n \"event\" text,\n \"round\" real,\n \"time\" text,\n \"location\" text\n);\n\nQuestion: Which event resulted in loss with an Opponent of maurice smith?" }, { "role": "assistant", "content": "SELECT \"event\" FROM \"mixed_martial_arts_record\" WHERE \"res\"='loss' AND \"opponent\"='maurice smith';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"changes_in_medal_standings\" (\n \"sport\" text,\n \"event\" text,\n \"nation\" text,\n \"gold\" text,\n \"silver\" text,\n \"bronze\" text,\n \"total\" text\n);\n\nQuestion: What is the winner of gold that also has \u2193 1 in the sport of cycling?" }, { "role": "assistant", "content": "SELECT \"gold\" FROM \"changes_in_medal_standings\" WHERE \"bronze\"='\u2193 1' AND \"sport\"='cycling';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"complete_24_hours_of_le_mans_results\" (\n \"year\" real,\n \"team\" text,\n \"co_drivers\" text,\n \"class\" text,\n \"pos\" text,\n \"class_pos\" text\n);\n\nQuestion: What is the most recent year that Gulf Racing Middle East won?" }, { "role": "assistant", "content": "SELECT MAX(\"year\") FROM \"complete_24_hours_of_le_mans_results\" WHERE \"team\"='gulf racing middle east';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"complete_24_hours_of_le_mans_results\" (\n \"year\" real,\n \"team\" text,\n \"co_drivers\" text,\n \"class\" text,\n \"pos\" text,\n \"class_pos\" text\n);\n\nQuestion: What is the class of the co-driver emanuele pirro jj lehto?" }, { "role": "assistant", "content": "SELECT \"class\" FROM \"complete_24_hours_of_le_mans_results\" WHERE \"co_drivers\"='emanuele pirro jj lehto';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"complete_24_hours_of_le_mans_results\" (\n \"year\" real,\n \"team\" text,\n \"co_drivers\" text,\n \"class\" text,\n \"pos\" text,\n \"class_pos\" text\n);\n\nQuestion: What was the final position of Arena Motorsports International?" }, { "role": "assistant", "content": "SELECT \"pos\" FROM \"complete_24_hours_of_le_mans_results\" WHERE \"team\"='arena motorsports international';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"complete_24_hours_of_le_mans_results\" (\n \"year\" real,\n \"team\" text,\n \"co_drivers\" text,\n \"class\" text,\n \"pos\" text,\n \"class_pos\" text\n);\n\nQuestion: Who was the Co-Driver of the winner of 1992's race?" }, { "role": "assistant", "content": "SELECT \"co_drivers\" FROM \"complete_24_hours_of_le_mans_results\" WHERE \"year\"=1992;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"singles_5_3_titles_2_runner_ups\" (\n \"outcome\" text,\n \"date\" text,\n \"surface\" text,\n \"opponent_in_the_final\" text,\n \"score_in_the_final\" text\n);\n\nQuestion: What is the score in the final with runner-up as the outcome and hard (i) as the surface?" }, { "role": "assistant", "content": "SELECT \"score_in_the_final\" FROM \"singles_5_3_titles_2_runner_ups\" WHERE \"outcome\"='runner-up' AND \"surface\"='hard (i)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"second_round\" (\n \"team_1\" text,\n \"agg\" text,\n \"team_2\" text,\n \"1st_leg\" text,\n \"2nd_leg\" text\n);\n\nQuestion: Who is team 1 when 2nd leg score is 1-3 and Asec Mimosas is Team 2?" }, { "role": "assistant", "content": "SELECT \"team_1\" FROM \"second_round\" WHERE \"2nd_leg\"='1-3' AND \"team_2\"='asec mimosas';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"second_round\" (\n \"team_1\" text,\n \"agg\" text,\n \"team_2\" text,\n \"1st_leg\" text,\n \"2nd_leg\" text\n);\n\nQuestion: What is the 1st leg score when 2nd leg score is 3-3?" }, { "role": "assistant", "content": "SELECT \"1st_leg\" FROM \"second_round\" WHERE \"2nd_leg\"='3-3';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"second_round\" (\n \"team_1\" text,\n \"agg\" text,\n \"team_2\" text,\n \"1st_leg\" text,\n \"2nd_leg\" text\n);\n\nQuestion: What is the 1st leg score when US Mbila Nzambi is team 1?" }, { "role": "assistant", "content": "SELECT \"1st_leg\" FROM \"second_round\" WHERE \"team_1\"='us mbila nzambi';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: Who was the opponent on May 20?" }, { "role": "assistant", "content": "SELECT \"opponent\" FROM \"game_log\" WHERE \"date\"='may 20';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: Who took the loss on May 25?" }, { "role": "assistant", "content": "SELECT \"loss\" FROM \"game_log\" WHERE \"date\"='may 25';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What was the record after the game that ended in a 2-3 loss?" }, { "role": "assistant", "content": "SELECT \"record\" FROM \"game_log\" WHERE \"score\"='2-3';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What was the date of the game that had a loss of Politte (0-2)?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"game_log\" WHERE \"loss\"='politte (0-2)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: Who was the opponent at the game that had a loss of Hendrickson (0-1)?" }, { "role": "assistant", "content": "SELECT \"opponent\" FROM \"game_log\" WHERE \"loss\"='hendrickson (0-1)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What was the smallest attendance at a game when the record was 7-15?" }, { "role": "assistant", "content": "SELECT MIN(\"attendance\") FROM \"game_log\" WHERE \"record\"='7-15';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What was the average attendance at a game when the record was 6-13?" }, { "role": "assistant", "content": "SELECT AVG(\"attendance\") FROM \"game_log\" WHERE \"record\"='6-13';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"principle\" (\n \"group\" real,\n \"half_life_s\" real,\n \"decay_constant_s_1\" real,\n \"yield_neutrons_per_fission\" real,\n \"fraction\" real\n);\n\nQuestion: What is the yield, neutrons per fission of the group with decay constants less than 0.301, a half-life of 22.72, and a group number larger than 2?" }, { "role": "assistant", "content": "SELECT SUM(\"yield_neutrons_per_fission\") FROM \"principle\" WHERE \"decay_constant_s_1\"<0.301 AND \"half_life_s\"=22.72 AND \"group\">2;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"principle\" (\n \"group\" real,\n \"half_life_s\" real,\n \"decay_constant_s_1\" real,\n \"yield_neutrons_per_fission\" real,\n \"fraction\" real\n);\n\nQuestion: What is the decay constant with a half-life less than 22.72, a yield, neutrons per fission of 0.0031000000000000003, and a group number less than 3?" }, { "role": "assistant", "content": "SELECT COUNT(\"decay_constant_s_1\") FROM \"principle\" WHERE \"half_life_s\"<22.72 AND \"yield_neutrons_per_fission\"=0.0031000000000000003 AND \"group\"<3;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"principle\" (\n \"group\" real,\n \"half_life_s\" real,\n \"decay_constant_s_1\" real,\n \"yield_neutrons_per_fission\" real,\n \"fraction\" real\n);\n\nQuestion: What is the lowest half-life with a yield, neutrons per fission bigger than 0.0031000000000000003 and a decay constant less than 0.030500000000000003?" }, { "role": "assistant", "content": "SELECT MIN(\"half_life_s\") FROM \"principle\" WHERE \"yield_neutrons_per_fission\">0.0031000000000000003 AND \"decay_constant_s_1\"<0.030500000000000003;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"indianapolis_colts_draft_history\" (\n \"round\" real,\n \"pick_num\" real,\n \"overall\" real,\n \"name\" text,\n \"position\" text,\n \"college\" text\n);\n\nQuestion: With Round 3 and Pick # over 10, what is the higher Overall number?" }, { "role": "assistant", "content": "SELECT MAX(\"overall\") FROM \"indianapolis_colts_draft_history\" WHERE \"round\"=3 AND \"pick_num\">10;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"indianapolis_colts_draft_history\" (\n \"round\" real,\n \"pick_num\" real,\n \"overall\" real,\n \"name\" text,\n \"position\" text,\n \"college\" text\n);\n\nQuestion: What is the highest round for College of Nebraska if the Overall is under 190?" }, { "role": "assistant", "content": "SELECT MAX(\"round\") FROM \"indianapolis_colts_draft_history\" WHERE \"college\"='nebraska' AND \"overall\"<190;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"indianapolis_colts_draft_history\" (\n \"round\" real,\n \"pick_num\" real,\n \"overall\" real,\n \"name\" text,\n \"position\" text,\n \"college\" text\n);\n\nQuestion: Which college has a Pick # 1, Overall more than one, and Round is 7?" }, { "role": "assistant", "content": "SELECT \"college\" FROM \"indianapolis_colts_draft_history\" WHERE \"pick_num\"=1 AND \"overall\">1 AND \"round\"=7;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"fa_premier_league\" (\n \"date\" text,\n \"opponents\" text,\n \"result_f_a\" text,\n \"attendance\" real,\n \"league_position\" text\n);\n\nQuestion: What was the attendance on 21 August 2004?" }, { "role": "assistant", "content": "SELECT SUM(\"attendance\") FROM \"fa_premier_league\" WHERE \"date\"='21 august 2004';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"semifinal_2\" (\n \"rank\" real,\n \"lane\" real,\n \"name\" text,\n \"nationality\" text,\n \"time\" real\n);\n\nQuestion: What is the average rank of an athlete that holds a time higher than 53.38?" }, { "role": "assistant", "content": "SELECT AVG(\"rank\") FROM \"semifinal_2\" WHERE \"time\">53.38;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"semifinal_2\" (\n \"rank\" real,\n \"lane\" real,\n \"name\" text,\n \"nationality\" text,\n \"time\" real\n);\n\nQuestion: What lane did the swimmer with a time of 52.84 have?" }, { "role": "assistant", "content": "SELECT MAX(\"lane\") FROM \"semifinal_2\" WHERE \"time\"=52.84;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"semifinal_2\" (\n \"rank\" real,\n \"lane\" real,\n \"name\" text,\n \"nationality\" text,\n \"time\" real\n);\n\nQuestion: What lane did the rank 3 swimmer use?" }, { "role": "assistant", "content": "SELECT MAX(\"lane\") FROM \"semifinal_2\" WHERE \"rank\"=3;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: Which opponent played on July 15?" }, { "role": "assistant", "content": "SELECT \"opponent\" FROM \"game_log\" WHERE \"date\"='july 15';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: What is the record for a game played on July 16 with attendance of more than 32,162?" }, { "role": "assistant", "content": "SELECT \"record\" FROM \"game_log\" WHERE \"attendance\">'32,162' AND \"date\"='july 16';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"final_leaderboard\" (\n \"place\" text,\n \"player\" text,\n \"country\" text,\n \"score\" text,\n \"to_par\" text,\n \"money\" real\n);\n\nQuestion: Where has Jimmy Demaret as a player?" }, { "role": "assistant", "content": "SELECT \"place\" FROM \"final_leaderboard\" WHERE \"player\"='jimmy demaret';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"final_leaderboard\" (\n \"place\" text,\n \"player\" text,\n \"country\" text,\n \"score\" text,\n \"to_par\" text,\n \"money\" real\n);\n\nQuestion: How much does it cost for United States and Byron nelson?" }, { "role": "assistant", "content": "SELECT COUNT(\"money\") FROM \"final_leaderboard\" WHERE \"country\"='united states' AND \"player\"='byron nelson';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"final_leaderboard\" (\n \"place\" text,\n \"player\" text,\n \"country\" text,\n \"score\" text,\n \"to_par\" text,\n \"money\" real\n);\n\nQuestion: Which Country has a Place of t8 and byron nelson?" }, { "role": "assistant", "content": "SELECT \"country\" FROM \"final_leaderboard\" WHERE \"place\"='t8' AND \"player\"='byron nelson';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"list_of_japanese_prefectural_capitals\" (\n \"capital\" text,\n \"prefecture\" text,\n \"region\" text,\n \"island\" text,\n \"pop\" real\n);\n\nQuestion: Name the average pop for ch\u016bgoku and prefecture of okayama" }, { "role": "assistant", "content": "SELECT AVG(\"pop\") FROM \"list_of_japanese_prefectural_capitals\" WHERE \"region\"='ch\u016bgoku' AND \"prefecture\"='okayama';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"list_of_japanese_prefectural_capitals\" (\n \"capital\" text,\n \"prefecture\" text,\n \"region\" text,\n \"island\" text,\n \"pop\" real\n);\n\nQuestion: Name the highest pop for tottori" }, { "role": "assistant", "content": "SELECT MAX(\"pop\") FROM \"list_of_japanese_prefectural_capitals\" WHERE \"prefecture\"='tottori';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"list_of_japanese_prefectural_capitals\" (\n \"capital\" text,\n \"prefecture\" text,\n \"region\" text,\n \"island\" text,\n \"pop\" real\n);\n\nQuestion: Name the sum of pop for shizuoka" }, { "role": "assistant", "content": "SELECT SUM(\"pop\") FROM \"list_of_japanese_prefectural_capitals\" WHERE \"prefecture\"='shizuoka';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"list_of_japanese_prefectural_capitals\" (\n \"capital\" text,\n \"prefecture\" text,\n \"region\" text,\n \"island\" text,\n \"pop\" real\n);\n\nQuestion: Name the total number of pop for ibaraki" }, { "role": "assistant", "content": "SELECT COUNT(\"pop\") FROM \"list_of_japanese_prefectural_capitals\" WHERE \"prefecture\"='ibaraki';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_members\" (\n \"school\" text,\n \"location\" text,\n \"mascot\" text,\n \"county\" text,\n \"enrollment_ihsaa_class\" text,\n \"joined\" real,\n \"previous_conference\" text\n);\n\nQuestion: Who is the mascot for Mishawaka?" }, { "role": "assistant", "content": "SELECT \"mascot\" FROM \"current_members\" WHERE \"location\"='mishawaka';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_members\" (\n \"school\" text,\n \"location\" text,\n \"mascot\" text,\n \"county\" text,\n \"enrollment_ihsaa_class\" text,\n \"joined\" real,\n \"previous_conference\" text\n);\n\nQuestion: Which previous conference is associated with Penn school?" }, { "role": "assistant", "content": "SELECT \"previous_conference\" FROM \"current_members\" WHERE \"school\"='penn';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_members\" (\n \"school\" text,\n \"location\" text,\n \"mascot\" text,\n \"county\" text,\n \"enrollment_ihsaa_class\" text,\n \"joined\" real,\n \"previous_conference\" text\n);\n\nQuestion: Which location is in 71 St. Joseph county with South Bend Washington school?" }, { "role": "assistant", "content": "SELECT \"location\" FROM \"current_members\" WHERE \"county\"='71 st. joseph' AND \"school\"='south bend washington';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"current_members\" (\n \"school\" text,\n \"location\" text,\n \"mascot\" text,\n \"county\" text,\n \"enrollment_ihsaa_class\" text,\n \"joined\" real,\n \"previous_conference\" text\n);\n\nQuestion: What is the mascot for South Bend Clay?" }, { "role": "assistant", "content": "SELECT \"mascot\" FROM \"current_members\" WHERE \"school\"='south bend clay';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"timeline_of_tallest_buildings\" (\n \"name\" text,\n \"street_address\" text,\n \"years_as_tallest\" text,\n \"height_ft_m\" text,\n \"floors\" text,\n \"architect\" text\n);\n\nQuestion: What was the address of the building with architects Edmund Woolley and Andrew Hamilton?" }, { "role": "assistant", "content": "SELECT \"street_address\" FROM \"timeline_of_tallest_buildings\" WHERE \"architect\"='edmund woolley and andrew hamilton';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"timeline_of_tallest_buildings\" (\n \"name\" text,\n \"street_address\" text,\n \"years_as_tallest\" text,\n \"height_ft_m\" text,\n \"floors\" text,\n \"architect\" text\n);\n\nQuestion: How many years as tallest building was the Tenth Presbyterian Church?" }, { "role": "assistant", "content": "SELECT \"years_as_tallest\" FROM \"timeline_of_tallest_buildings\" WHERE \"name\"='tenth presbyterian church';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"timeline_of_tallest_buildings\" (\n \"name\" text,\n \"street_address\" text,\n \"years_as_tallest\" text,\n \"height_ft_m\" text,\n \"floors\" text,\n \"architect\" text\n);\n\nQuestion: How many years as tallest building was Independence Hall?" }, { "role": "assistant", "content": "SELECT \"years_as_tallest\" FROM \"timeline_of_tallest_buildings\" WHERE \"name\"='independence hall';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"timeline_of_tallest_buildings\" (\n \"name\" text,\n \"street_address\" text,\n \"years_as_tallest\" text,\n \"height_ft_m\" text,\n \"floors\" text,\n \"architect\" text\n);\n\nQuestion: What is the height of the Tenth Presbyterian Church?" }, { "role": "assistant", "content": "SELECT \"height_ft_m\" FROM \"timeline_of_tallest_buildings\" WHERE \"name\"='tenth presbyterian church';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: For the Loss of Plesac (1-5), what is the Record?" }, { "role": "assistant", "content": "SELECT \"record\" FROM \"game_log\" WHERE \"loss\"='plesac (1-5)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"date\" text,\n \"opponent\" text,\n \"score\" text,\n \"loss\" text,\n \"attendance\" real,\n \"record\" text\n);\n\nQuestion: For the Loss of Plesac (1-5), what is the Record?" }, { "role": "assistant", "content": "SELECT \"record\" FROM \"game_log\" WHERE \"loss\"='plesac (1-5)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"complete_formula_one_world_championship_\" (\n \"year\" real,\n \"entrant\" text,\n \"chassis\" text,\n \"engine\" text,\n \"points\" real\n);\n\nQuestion: Name the entrant for year less than 1990 and chassis of eurobrun er189" }, { "role": "assistant", "content": "SELECT \"entrant\" FROM \"complete_formula_one_world_championship_\" WHERE \"year\"<1990 AND \"chassis\"='eurobrun er189';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"complete_formula_one_world_championship_\" (\n \"year\" real,\n \"entrant\" text,\n \"chassis\" text,\n \"engine\" text,\n \"points\" real\n);\n\nQuestion: Name the engine for years before 1990 and chassis of eurobrun er189" }, { "role": "assistant", "content": "SELECT \"engine\" FROM \"complete_formula_one_world_championship_\" WHERE \"year\"<1990 AND \"chassis\"='eurobrun er189';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"statistics\" (\n \"year\" text,\n \"games_played\" real,\n \"games_started\" real,\n \"attempts\" real,\n \"yards\" real,\n \"touchdowns\" real,\n \"receptions\" real,\n \"rec_yards\" real,\n \"rec_touchdowns\" real,\n \"fumbles\" real\n);\n\nQuestion: With games started smaller than 16 plus receptions of 51, what is the smallest amount of touchdowns listed?" }, { "role": "assistant", "content": "SELECT MIN(\"touchdowns\") FROM \"statistics\" WHERE \"receptions\"=51 AND \"games_started\"<16;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"statistics\" (\n \"year\" text,\n \"games_played\" real,\n \"games_started\" real,\n \"attempts\" real,\n \"yards\" real,\n \"touchdowns\" real,\n \"receptions\" real,\n \"rec_yards\" real,\n \"rec_touchdowns\" real,\n \"fumbles\" real\n);\n\nQuestion: What are the highest number of games played that had game starts of 10, receptions of 6 and fumbles smaller than 3?" }, { "role": "assistant", "content": "SELECT MAX(\"games_played\") FROM \"statistics\" WHERE \"receptions\"=6 AND \"games_started\"=10 AND \"fumbles\"<3;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2011\" (\n \"date\" text,\n \"location\" text,\n \"nature_of_incident\" text,\n \"circumstances\" text,\n \"casualties\" text\n);\n\nQuestion: When was the location 15km NW of Pol-E Khomri, the circumstaances IED and the casualties of 1 WIA?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"2011\" WHERE \"casualties\"='1 wia' AND \"circumstances\"='ied' AND \"location\"='15km nw of pol-e khomri';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2011\" (\n \"date\" text,\n \"location\" text,\n \"nature_of_incident\" text,\n \"circumstances\" text,\n \"casualties\" text\n);\n\nQuestion: When was the incident in Pol-E Khomri?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"2011\" WHERE \"location\"='pol-e khomri';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2011\" (\n \"date\" text,\n \"location\" text,\n \"nature_of_incident\" text,\n \"circumstances\" text,\n \"casualties\" text\n);\n\nQuestion: What was the incident in imam sahib area, kunduz province?" }, { "role": "assistant", "content": "SELECT \"nature_of_incident\" FROM \"2011\" WHERE \"location\"='imam sahib area, kunduz province';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"list_of_hostages\" (\n \"romanized_name\" text,\n \"name_in_hangul\" text,\n \"name_in_hanja\" text,\n \"gender\" text,\n \"birth_year\" real\n);\n\nQuestion: What gender has Romanized name and kim yoon-yeong?" }, { "role": "assistant", "content": "SELECT \"gender\" FROM \"list_of_hostages\" WHERE \"romanized_name\"='kim yoon-yeong';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"career_statistics\" (\n \"year\" real,\n \"team\" text,\n \"games\" real,\n \"attempts\" real,\n \"yards\" real\n);\n\nQuestion: What year did Willis McGahee play fewer than 15 games with the Baltimore Ravens?" }, { "role": "assistant", "content": "SELECT MIN(\"year\") FROM \"career_statistics\" WHERE \"team\"='baltimore ravens' AND \"games\"<15;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"career_statistics\" (\n \"year\" real,\n \"team\" text,\n \"games\" real,\n \"attempts\" real,\n \"yards\" real\n);\n\nQuestion: After the 2013 season, what was the fewest number of games that Willis McGahee played in a single season?" }, { "role": "assistant", "content": "SELECT MIN(\"games\") FROM \"career_statistics\" WHERE \"year\">2013;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"international_goals\" (\n \"date\" text,\n \"venue\" text,\n \"score\" text,\n \"result\" text,\n \"competition\" text\n);\n\nQuestion: What is the result when the competition was the 2006 fifa world cup qualifier, and a Venue of warner park sporting complex, bassaterre?" }, { "role": "assistant", "content": "SELECT \"result\" FROM \"international_goals\" WHERE \"competition\"='2006 fifa world cup qualifier' AND \"venue\"='warner park sporting complex, bassaterre';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"international_goals\" (\n \"date\" text,\n \"venue\" text,\n \"score\" text,\n \"result\" text,\n \"competition\" text\n);\n\nQuestion: What is the name of the venue when the competition was friendly, with a Result of 2\u20133?" }, { "role": "assistant", "content": "SELECT \"venue\" FROM \"international_goals\" WHERE \"competition\"='friendly' AND \"result\"='2\u20133';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"international_goals\" (\n \"date\" text,\n \"venue\" text,\n \"score\" text,\n \"result\" text,\n \"competition\" text\n);\n\nQuestion: What is the name of the venue when the score was 5\u20130, and a Competition of 2007 caribbean cup qualifier?" }, { "role": "assistant", "content": "SELECT \"venue\" FROM \"international_goals\" WHERE \"score\"='5\u20130' AND \"competition\"='2007 caribbean cup qualifier';" } ]