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_13456202_1\" (\n \"school\" text,\n \"location\" text,\n \"founded\" real,\n \"affiliation\" text,\n \"mascot\" text,\n \"division\" text\n);\n\nQuestion: WHat year was north college hill high school founded?"
},
{
"role": "assistant",
"content": "SELECT MAX(\"founded\") FROM \"table1_13456202_1\" WHERE \"school\"='North College Hill High School';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"united_states_house_of_representatives_e\" (\n \"district\" text,\n \"incumbent\" text,\n \"party\" text,\n \"first_elected\" real,\n \"result\" text,\n \"candidates\" text\n);\n\nQuestion: Who was the incumbent when ran william b. oliver (d) unopposed?"
},
{
"role": "assistant",
"content": "SELECT \"incumbent\" FROM \"united_states_house_of_representatives_e\" WHERE \"candidates\"='William B. Oliver (D) Unopposed';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"united_states_house_of_representatives_e\" (\n \"district\" text,\n \"incumbent\" text,\n \"party\" text,\n \"first_elected\" real,\n \"result\" text,\n \"candidates\" text\n);\n\nQuestion: Which party was the incumbent from when the cadidates were henry e. barbour (r) 52.1% henry hawson (d) 47.9%? Answer: Democratic"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"party\") FROM \"united_states_house_of_representatives_e\" WHERE \"candidates\"='Henry E. Barbour (R) 52.1% Henry Hawson (D) 47.9%';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"united_states_house_of_representatives_e\" (\n \"district\" text,\n \"incumbent\" text,\n \"party\" text,\n \"first_elected\" real,\n \"result\" text,\n \"candidates\" text\n);\n\nQuestion: Which district was the race between john i. nolan (r) 87% thomas f. feeley (s) 13%?"
},
{
"role": "assistant",
"content": "SELECT \"district\" FROM \"united_states_house_of_representatives_e\" WHERE \"candidates\"='John I. Nolan (R) 87% Thomas F. Feeley (S) 13%';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"united_states_house_of_representatives_e\" (\n \"district\" text,\n \"incumbent\" text,\n \"party\" text,\n \"first_elected\" real,\n \"result\" text,\n \"candidates\" text\n);\n\nQuestion: What was the net seat gain in the race john a. elston (r) 88.4% luella twining (s) 11.6%?"
},
{
"role": "assistant",
"content": "SELECT \"result\" FROM \"united_states_house_of_representatives_e\" WHERE \"candidates\"='John A. Elston (R) 88.4% Luella Twining (S) 11.6%';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"united_states_house_of_representatives_e\" (\n \"district\" text,\n \"incumbent\" text,\n \"party\" text,\n \"first_elected\" real,\n \"result\" text,\n \"candidates\" text\n);\n\nQuestion: Which District was the incumbent Julius Kahn from? Answer: California 4th district"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"district\") FROM \"united_states_house_of_representatives_e\" WHERE \"incumbent\"='Julius Kahn';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"united_states_house_of_representatives_e\" (\n \"district\" text,\n \"incumbent\" text,\n \"party\" text,\n \"first_elected\" real,\n \"result\" text,\n \"candidates\" text\n);\n\nQuestion: What was the result of the election when Clarence F. Lea was the incumbent?"
},
{
"role": "assistant",
"content": "SELECT \"result\" FROM \"united_states_house_of_representatives_e\" WHERE \"incumbent\"='Clarence F. Lea';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: Which team played in game 20?"
},
{
"role": "assistant",
"content": "SELECT \"team\" FROM \"game_log\" WHERE \"game\"=20;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"tallest_under_construction_buildings\" (\n \"rank\" real,\n \"name\" text,\n \"city\" text,\n \"region\" text,\n \"height_m\" real,\n \"height_ft\" real,\n \"floors\" real,\n \"estimated_completion\" real\n);\n\nQuestion: what's the\u00a0height (ft)\u00a0with\u00a0name\u00a0being leadenhall building"
},
{
"role": "assistant",
"content": "SELECT \"height_ft\" FROM \"tallest_under_construction_buildings\" WHERE \"name\"='Leadenhall Building';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"tallest_under_construction_buildings\" (\n \"rank\" real,\n \"name\" text,\n \"city\" text,\n \"region\" text,\n \"height_m\" real,\n \"height_ft\" real,\n \"floors\" real,\n \"estimated_completion\" real\n);\n\nQuestion: what's the\u00a0height (ft)\u00a0with\u00a0name\u00a0being 52-54 lime street"
},
{
"role": "assistant",
"content": "SELECT \"height_ft\" FROM \"tallest_under_construction_buildings\" WHERE \"name\"='52-54 Lime Street';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"tallest_under_construction_buildings\" (\n \"rank\" real,\n \"name\" text,\n \"city\" text,\n \"region\" text,\n \"height_m\" real,\n \"height_ft\" real,\n \"floors\" real,\n \"estimated_completion\" real\n);\n\nQuestion: how many\u00a0city\u00a0with\u00a0name\u00a0being providence tower"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"city\") FROM \"tallest_under_construction_buildings\" WHERE \"name\"='Providence Tower';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table1_134729_3\" (\n \"frequency\" text,\n \"call_sign\" text,\n \"name\" text,\n \"format\" text,\n \"owner\" text,\n \"target_city_market\" text,\n \"city_of_license\" text\n);\n\nQuestion: What station has the call number K213cl"
},
{
"role": "assistant",
"content": "SELECT \"format\" FROM \"table1_134729_3\" WHERE \"call_sign\"='K213CL';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table1_134729_3\" (\n \"frequency\" text,\n \"call_sign\" text,\n \"name\" text,\n \"format\" text,\n \"owner\" text,\n \"target_city_market\" text,\n \"city_of_license\" text\n);\n\nQuestion: What market is Wessington Springs in"
},
{
"role": "assistant",
"content": "SELECT \"target_city_market\" FROM \"table1_134729_3\" WHERE \"city_of_license\"='Wessington Springs';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table1_134729_3\" (\n \"frequency\" text,\n \"call_sign\" text,\n \"name\" text,\n \"format\" text,\n \"owner\" text,\n \"target_city_market\" text,\n \"city_of_license\" text\n);\n\nQuestion: What station owns Moody Bible Institute"
},
{
"role": "assistant",
"content": "SELECT \"format\" FROM \"table1_134729_3\" WHERE \"owner\"='Moody Bible Institute';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: how many\u00a0date\u00a0with\u00a0score\u00a0being w 113\u201387"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"date\") FROM \"game_log\" WHERE \"score\"='W 113\u201387';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: what's the\u00a0game\u00a0with\u00a0record\u00a0being 29\u20133"
},
{
"role": "assistant",
"content": "SELECT \"game\" FROM \"game_log\" WHERE \"record\"='29\u20133';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: who is the the\u00a0high rebounds\u00a0with\u00a0high assbeingts\u00a0being scottie pippen (9)"
},
{
"role": "assistant",
"content": "SELECT \"high_rebounds\" FROM \"game_log\" WHERE \"high_assists\"='Scottie Pippen (9)';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: who is the the\u00a0high points\u00a0with\u00a0score\u00a0being w 117\u201393"
},
{
"role": "assistant",
"content": "SELECT \"high_points\" FROM \"game_log\" WHERE \"score\"='W 117\u201393';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: what's the\u00a0record\u00a0with\u00a0date\u00a0being january 13"
},
{
"role": "assistant",
"content": "SELECT \"record\" FROM \"game_log\" WHERE \"date\"='January 13';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: what are all the record where date is january 21"
},
{
"role": "assistant",
"content": "SELECT \"record\" FROM \"game_log\" WHERE \"date\"='January 21';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table1_134987_3\" (\n \"frequency\" text,\n \"call_sign\" text,\n \"name\" text,\n \"format\" text,\n \"owner\" text,\n \"target_city_market\" text,\n \"city_of_license\" text\n);\n\nQuestion: What is the name of Rapid City's Adult Contemporary station?"
},
{
"role": "assistant",
"content": "SELECT \"name\" FROM \"table1_134987_3\" WHERE \"city_of_license\"='Rapid City' AND \"format\"='Adult Contemporary';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table1_134987_3\" (\n \"frequency\" text,\n \"call_sign\" text,\n \"name\" text,\n \"format\" text,\n \"owner\" text,\n \"target_city_market\" text,\n \"city_of_license\" text\n);\n\nQuestion: What are the market city/market(s) for Rapid City Alternative format?"
},
{
"role": "assistant",
"content": "SELECT \"target_city_market\" FROM \"table1_134987_3\" WHERE \"city_of_license\"='Rapid City' AND \"format\"='Alternative';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table1_134987_3\" (\n \"frequency\" text,\n \"call_sign\" text,\n \"name\" text,\n \"format\" text,\n \"owner\" text,\n \"target_city_market\" text,\n \"city_of_license\" text\n);\n\nQuestion: What is the frequency for the Christian Kawz-fm Translator station?"
},
{
"role": "assistant",
"content": "SELECT \"frequency\" FROM \"table1_134987_3\" WHERE \"format\"='Christian KAWZ-FM translator';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table1_134987_3\" (\n \"frequency\" text,\n \"call_sign\" text,\n \"name\" text,\n \"format\" text,\n \"owner\" text,\n \"target_city_market\" text,\n \"city_of_license\" text\n);\n\nQuestion: What is the target market for the station on 97.9 fm?"
},
{
"role": "assistant",
"content": "SELECT \"target_city_market\" FROM \"table1_134987_3\" WHERE \"frequency\"='97.9 FM';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table1_134987_3\" (\n \"frequency\" text,\n \"call_sign\" text,\n \"name\" text,\n \"format\" text,\n \"owner\" text,\n \"target_city_market\" text,\n \"city_of_license\" text\n);\n\nQuestion: What is the frequency of the Classic Country Krki-fm booster station?"
},
{
"role": "assistant",
"content": "SELECT \"frequency\" FROM \"table1_134987_3\" WHERE \"format\"='Classic Country KRKI-FM booster';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table1_134987_3\" (\n \"frequency\" text,\n \"call_sign\" text,\n \"name\" text,\n \"format\" text,\n \"owner\" text,\n \"target_city_market\" text,\n \"city_of_license\" text\n);\n\nQuestion: What is the target market of the station with call sign KFXS?"
},
{
"role": "assistant",
"content": "SELECT \"target_city_market\" FROM \"table1_134987_3\" WHERE \"call_sign\"='KFXS';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"american_television_ratings\" (\n \"season\" text,\n \"timeslot\" text,\n \"season_premiere\" text,\n \"season_finale\" text,\n \"episodes\" real,\n \"tv_season\" text,\n \"ranking\" text,\n \"viewers_in_millions\" text\n);\n\nQuestion: What year did the season finale have a total of 10.29 million viewers?"
},
{
"role": "assistant",
"content": "SELECT \"season_finale\" FROM \"american_television_ratings\" WHERE \"viewers_in_millions\"='10.29';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"american_television_ratings\" (\n \"season\" text,\n \"timeslot\" text,\n \"season_premiere\" text,\n \"season_finale\" text,\n \"episodes\" real,\n \"tv_season\" text,\n \"ranking\" text,\n \"viewers_in_millions\" text\n);\n\nQuestion: In what TV season did the 3rd season air?"
},
{
"role": "assistant",
"content": "SELECT \"tv_season\" FROM \"american_television_ratings\" WHERE \"season\"='3rd';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"american_television_ratings\" (\n \"season\" text,\n \"timeslot\" text,\n \"season_premiere\" text,\n \"season_finale\" text,\n \"episodes\" real,\n \"tv_season\" text,\n \"ranking\" text,\n \"viewers_in_millions\" text\n);\n\nQuestion: How many rankings did the 5th season have?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"ranking\") FROM \"american_television_ratings\" WHERE \"season\"='5th';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"american_television_ratings\" (\n \"season\" text,\n \"timeslot\" text,\n \"season_premiere\" text,\n \"season_finale\" text,\n \"episodes\" real,\n \"tv_season\" text,\n \"ranking\" text,\n \"viewers_in_millions\" text\n);\n\nQuestion: How many times did the 2nd season have a finale?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"season_finale\") FROM \"american_television_ratings\" WHERE \"season\"='2nd';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"nevada_places_ranked_by_per_capita_incom\" (\n \"rank\" real,\n \"place\" text,\n \"county\" text,\n \"per_capita_income\" text,\n \"median_house_hold_income\" text,\n \"population\" real,\n \"number_of_households\" real\n);\n\nQuestion: how many\u00a0county\u00a0with\u00a0per capita income\u00a0being $20,101"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"county\") FROM \"nevada_places_ranked_by_per_capita_incom\" WHERE \"per_capita_income\"='$20,101';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"nevada_places_ranked_by_per_capita_incom\" (\n \"rank\" real,\n \"place\" text,\n \"county\" text,\n \"per_capita_income\" text,\n \"median_house_hold_income\" text,\n \"population\" real,\n \"number_of_households\" real\n);\n\nQuestion: who is the the\u00a0place\u00a0with\u00a0per capita income\u00a0being $14,793"
},
{
"role": "assistant",
"content": "SELECT \"place\" FROM \"nevada_places_ranked_by_per_capita_incom\" WHERE \"per_capita_income\"='$14,793';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"nevada_places_ranked_by_per_capita_incom\" (\n \"rank\" real,\n \"place\" text,\n \"county\" text,\n \"per_capita_income\" text,\n \"median_house_hold_income\" text,\n \"population\" real,\n \"number_of_households\" real\n);\n\nQuestion: what's the\u00a0number of households\u00a0with\u00a0per capita income\u00a0being $16,820"
},
{
"role": "assistant",
"content": "SELECT \"number_of_households\" FROM \"nevada_places_ranked_by_per_capita_incom\" WHERE \"per_capita_income\"='$16,820';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"nevada_places_ranked_by_per_capita_incom\" (\n \"rank\" real,\n \"place\" text,\n \"county\" text,\n \"per_capita_income\" text,\n \"median_house_hold_income\" text,\n \"population\" real,\n \"number_of_households\" real\n);\n\nQuestion: what is the maximum\u00a0rank\u00a0with\u00a0per capita income\u00a0being $17,013"
},
{
"role": "assistant",
"content": "SELECT MAX(\"rank\") FROM \"nevada_places_ranked_by_per_capita_incom\" WHERE \"per_capita_income\"='$17,013';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"race_starters\" (\n \"saddle_cloth\" real,\n \"horse\" text,\n \"trainer\" text,\n \"jockey\" text,\n \"weight_kg\" text,\n \"barrier\" real,\n \"placing\" text\n);\n\nQuestion: How old is Darryll Holland's horse"
},
{
"role": "assistant",
"content": "SELECT \"barrier\" FROM \"race_starters\" WHERE \"jockey\"='Darryll Holland';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"race_starters\" (\n \"saddle_cloth\" real,\n \"horse\" text,\n \"trainer\" text,\n \"jockey\" text,\n \"weight_kg\" text,\n \"barrier\" real,\n \"placing\" text\n);\n\nQuestion: how many people work with N Rawiller"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"trainer\") FROM \"race_starters\" WHERE \"jockey\"='N Rawiller';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"race_starters\" (\n \"saddle_cloth\" real,\n \"horse\" text,\n \"trainer\" text,\n \"jockey\" text,\n \"weight_kg\" text,\n \"barrier\" real,\n \"placing\" text\n);\n\nQuestion: How old is Daniel Morton"
},
{
"role": "assistant",
"content": "SELECT MAX(\"barrier\") FROM \"race_starters\" WHERE \"trainer\"='Daniel Morton';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"d_r\" (\n \"serial_branch\" real,\n \"seaman\" text,\n \"mechanical\" text,\n \"secretariat\" text,\n \"supply\" text,\n \"electrical\" text,\n \"radio_electrical\" text,\n \"regulating\" text,\n \"medical\" text\n);\n\nQuestion: How many serial branches have radio electrial = rea-iv?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"serial_branch\") FROM \"d_r\" WHERE \"radio_electrical\"='REA-IV';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"d_r\" (\n \"serial_branch\" real,\n \"seaman\" text,\n \"mechanical\" text,\n \"secretariat\" text,\n \"supply\" text,\n \"electrical\" text,\n \"radio_electrical\" text,\n \"regulating\" text,\n \"medical\" text\n);\n\nQuestion: What are radio electricals when secretariat is wtr i?"
},
{
"role": "assistant",
"content": "SELECT \"radio_electrical\" FROM \"d_r\" WHERE \"secretariat\"='WTR I';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"d_r\" (\n \"serial_branch\" real,\n \"seaman\" text,\n \"mechanical\" text,\n \"secretariat\" text,\n \"supply\" text,\n \"electrical\" text,\n \"radio_electrical\" text,\n \"regulating\" text,\n \"medical\" text\n);\n\nQuestion: What are electricals where secretariat is po(w)?"
},
{
"role": "assistant",
"content": "SELECT \"electrical\" FROM \"d_r\" WHERE \"secretariat\"='PO(W)';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"d_r\" (\n \"serial_branch\" real,\n \"seaman\" text,\n \"mechanical\" text,\n \"secretariat\" text,\n \"supply\" text,\n \"electrical\" text,\n \"radio_electrical\" text,\n \"regulating\" text,\n \"medical\" text\n);\n\nQuestion: What mechanical has lpm regulation?"
},
{
"role": "assistant",
"content": "SELECT \"mechanical\" FROM \"d_r\" WHERE \"regulating\"='LPM';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"d_r\" (\n \"serial_branch\" real,\n \"seaman\" text,\n \"mechanical\" text,\n \"secretariat\" text,\n \"supply\" text,\n \"electrical\" text,\n \"radio_electrical\" text,\n \"regulating\" text,\n \"medical\" text\n);\n\nQuestion: How many branches have radio electrical=hon s lt(r)?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"serial_branch\") FROM \"d_r\" WHERE \"radio_electrical\"='Hon S Lt(R)';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"d_r\" (\n \"serial_branch\" real,\n \"seaman\" text,\n \"mechanical\" text,\n \"secretariat\" text,\n \"supply\" text,\n \"electrical\" text,\n \"radio_electrical\" text,\n \"regulating\" text,\n \"medical\" text\n);\n\nQuestion: Who regulates radio electrical = lren?"
},
{
"role": "assistant",
"content": "SELECT \"regulating\" FROM \"d_r\" WHERE \"radio_electrical\"='LREN';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"season_two_1999_2000\" (\n \"series_number\" real,\n \"season_number\" real,\n \"episode_title\" text,\n \"premiere_date\" text,\n \"production_code\" real\n);\n\nQuestion: What number episode in the series is the episode \"things that fly\"?"
},
{
"role": "assistant",
"content": "SELECT MAX(\"series_number\") FROM \"season_two_1999_2000\" WHERE \"episode_title\"='Things That Fly';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"season_two_1999_2000\" (\n \"series_number\" real,\n \"season_number\" real,\n \"episode_title\" text,\n \"premiere_date\" text,\n \"production_code\" real\n);\n\nQuestion: What is the production code for season episode 8?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"production_code\") FROM \"season_two_1999_2000\" WHERE \"season_number\"=8;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"season_two_1999_2000\" (\n \"series_number\" real,\n \"season_number\" real,\n \"episode_title\" text,\n \"premiere_date\" text,\n \"production_code\" real\n);\n\nQuestion: How many episodes have a series number of 35?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"episode_title\") FROM \"season_two_1999_2000\" WHERE \"series_number\"=35;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"season_two_1999_2000\" (\n \"series_number\" real,\n \"season_number\" real,\n \"episode_title\" text,\n \"premiere_date\" text,\n \"production_code\" real\n);\n\nQuestion: What is the series number for season episode 24?"
},
{
"role": "assistant",
"content": "SELECT MIN(\"series_number\") FROM \"season_two_1999_2000\" WHERE \"season_number\"=24;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"race_results\" (\n \"rnd\" real,\n \"race\" text,\n \"pole_position\" text,\n \"fastest_lap\" text,\n \"most_laps_led\" text,\n \"winning_driver\" text,\n \"winning_team\" text,\n \"report\" text\n);\n\nQuestion: how many have times of 6"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"fastest_lap\") FROM \"race_results\" WHERE \"rnd\"=6;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"race_results\" (\n \"rnd\" real,\n \"race\" text,\n \"pole_position\" text,\n \"fastest_lap\" text,\n \"most_laps_led\" text,\n \"winning_driver\" text,\n \"winning_team\" text,\n \"report\" text\n);\n\nQuestion: which brand have drivers who won with the names of ryan briscoe and tomas scheckter"
},
{
"role": "assistant",
"content": "SELECT \"winning_team\" FROM \"race_results\" WHERE \"winning_driver\"='Ryan Briscoe' AND \"fastest_lap\"='Tomas Scheckter';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"race_results\" (\n \"rnd\" real,\n \"race\" text,\n \"pole_position\" text,\n \"fastest_lap\" text,\n \"most_laps_led\" text,\n \"winning_driver\" text,\n \"winning_team\" text,\n \"report\" text\n);\n\nQuestion: who else along with scott dixon and graham rahal drove with the most speed"
},
{
"role": "assistant",
"content": "SELECT \"fastest_lap\" FROM \"race_results\" WHERE \"most_laps_led\"='Scott Dixon' AND \"pole_position\"='Graham Rahal';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"race_results\" (\n \"rnd\" real,\n \"race\" text,\n \"pole_position\" text,\n \"fastest_lap\" text,\n \"most_laps_led\" text,\n \"winning_driver\" text,\n \"winning_team\" text,\n \"report\" text\n);\n\nQuestion: tell the number of times where kansas was the location"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"rnd\") FROM \"race_results\" WHERE \"race\"='Kansas';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table1_1353096_2\" (\n \"city_of_license_market\" text,\n \"station\" text,\n \"channel_tv_dt\" text,\n \"years_owned\" text,\n \"current_status\" text\n);\n\nQuestion: What TV channel had a license from Boston?"
},
{
"role": "assistant",
"content": "SELECT \"channel_tv_dt\" FROM \"table1_1353096_2\" WHERE \"city_of_license_market\"='Boston';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table1_1353096_2\" (\n \"city_of_license_market\" text,\n \"station\" text,\n \"channel_tv_dt\" text,\n \"years_owned\" text,\n \"current_status\" text\n);\n\nQuestion: Which station has a license in Fort Collins, Colorado?"
},
{
"role": "assistant",
"content": "SELECT \"station\" FROM \"table1_1353096_2\" WHERE \"city_of_license_market\"='Fort Collins, Colorado';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table1_1353096_2\" (\n \"city_of_license_market\" text,\n \"station\" text,\n \"channel_tv_dt\" text,\n \"years_owned\" text,\n \"current_status\" text\n);\n\nQuestion: What is the current status of the KDAF ** Station?"
},
{
"role": "assistant",
"content": "SELECT \"current_status\" FROM \"table1_1353096_2\" WHERE \"station\"='KDAF **';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table1_1353096_2\" (\n \"city_of_license_market\" text,\n \"station\" text,\n \"channel_tv_dt\" text,\n \"years_owned\" text,\n \"current_status\" text\n);\n\nQuestion: How many entries are listed under \"current status\" for the WJW-TV ++ Station?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"current_status\") FROM \"table1_1353096_2\" WHERE \"station\"='WJW-TV ++';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"stations\" (\n \"city_of_license_market\" text,\n \"station\" text,\n \"channel_tv_dt\" text,\n \"owned_since\" text,\n \"primary_affiliation\" text\n);\n\nQuestion: How many stations have fox as the primary affiliation and have been owned since 1986?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"station\") FROM \"stations\" WHERE \"primary_affiliation\"='Fox' AND \"owned_since\"='1986';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"stations\" (\n \"city_of_license_market\" text,\n \"station\" text,\n \"channel_tv_dt\" text,\n \"owned_since\" text,\n \"primary_affiliation\" text\n);\n\nQuestion: What channel has station kdfw ++?"
},
{
"role": "assistant",
"content": "SELECT \"channel_tv_dt\" FROM \"stations\" WHERE \"station\"='KDFW ++';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"stations\" (\n \"city_of_license_market\" text,\n \"station\" text,\n \"channel_tv_dt\" text,\n \"owned_since\" text,\n \"primary_affiliation\" text\n);\n\nQuestion: What city has channel tv (dt) 25 (31)?"
},
{
"role": "assistant",
"content": "SELECT \"city_of_license_market\" FROM \"stations\" WHERE \"channel_tv_dt\"='25 (31)';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"stations\" (\n \"city_of_license_market\" text,\n \"station\" text,\n \"channel_tv_dt\" text,\n \"owned_since\" text,\n \"primary_affiliation\" text\n);\n\nQuestion: How many channel tv (dt)s are in austin, texas?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"channel_tv_dt\") FROM \"stations\" WHERE \"city_of_license_market\"='Austin, Texas';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"stations\" (\n \"city_of_license_market\" text,\n \"station\" text,\n \"channel_tv_dt\" text,\n \"owned_since\" text,\n \"primary_affiliation\" text\n);\n\nQuestion: When was 10 (10) bought?"
},
{
"role": "assistant",
"content": "SELECT \"owned_since\" FROM \"stations\" WHERE \"channel_tv_dt\"='10 (10)';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"west_australian_football_league_2001\" (\n \"season\" real,\n \"premiers\" text,\n \"runners_up\" text,\n \"score\" text,\n \"captain\" text,\n \"coach\" text,\n \"simpson_medal\" text,\n \"venue\" text,\n \"attendance\" real,\n \"umpires\" text\n);\n\nQuestion: Who were the umpires when Paul Medhurst (C) won the Simpson Medal?"
},
{
"role": "assistant",
"content": "SELECT \"umpires\" FROM \"west_australian_football_league_2001\" WHERE \"simpson_medal\"='Paul Medhurst (C)';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"west_australian_football_league_2001\" (\n \"season\" real,\n \"premiers\" text,\n \"runners_up\" text,\n \"score\" text,\n \"captain\" text,\n \"coach\" text,\n \"simpson_medal\" text,\n \"venue\" text,\n \"attendance\" real,\n \"umpires\" text\n);\n\nQuestion: Who were the umpires when Paul Vines (S) won the Simpson Medal?"
},
{
"role": "assistant",
"content": "SELECT \"umpires\" FROM \"west_australian_football_league_2001\" WHERE \"simpson_medal\"='Paul Vines (S)';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"west_australian_football_league_2001\" (\n \"season\" real,\n \"premiers\" text,\n \"runners_up\" text,\n \"score\" text,\n \"captain\" text,\n \"coach\" text,\n \"simpson_medal\" text,\n \"venue\" text,\n \"attendance\" real,\n \"umpires\" text\n);\n\nQuestion: Which venue did Luke Blackwell serve as captain?"
},
{
"role": "assistant",
"content": "SELECT \"venue\" FROM \"west_australian_football_league_2001\" WHERE \"captain\"='Luke Blackwell';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"women_s_statistics\" (\n \"player\" text,\n \"played\" real,\n \"sets_won\" real,\n \"sets_lost\" real,\n \"legs_won\" real,\n \"legs_lost\" real,\n \"100\" real,\n \"140\" real,\n \"180s\" real,\n \"high_checkout\" real,\n \"3_dart_average\" text\n);\n\nQuestion: what's the minimum 180s value"
},
{
"role": "assistant",
"content": "SELECT MIN(\"180s\") FROM \"women_s_statistics\";"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"women_s_statistics\" (\n \"player\" text,\n \"played\" real,\n \"sets_won\" real,\n \"sets_lost\" real,\n \"legs_won\" real,\n \"legs_lost\" real,\n \"100\" real,\n \"140\" real,\n \"180s\" real,\n \"high_checkout\" real,\n \"3_dart_average\" text\n);\n\nQuestion: what's the\u00a0sets won\u00a0with\u00a0140+\u00a0being 16"
},
{
"role": "assistant",
"content": "SELECT \"sets_won\" FROM \"women_s_statistics\" WHERE \"140\"=16;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"returning_this_year_after_a_break_of_one\" (\n \"programme\" text,\n \"date_s_of_original_removal\" text,\n \"original_channel\" text,\n \"date_s_of_return\" text,\n \"new_channel_s\" text\n);\n\nQuestion: What channel number is Gladiators on"
},
{
"role": "assistant",
"content": "SELECT \"new_channel_s\" FROM \"returning_this_year_after_a_break_of_one\" WHERE \"programme\"='Gladiators';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"returning_this_year_after_a_break_of_one\" (\n \"programme\" text,\n \"date_s_of_original_removal\" text,\n \"original_channel\" text,\n \"date_s_of_return\" text,\n \"new_channel_s\" text\n);\n\nQuestion: What show is coming back on in July 2008"
},
{
"role": "assistant",
"content": "SELECT \"programme\" FROM \"returning_this_year_after_a_break_of_one\" WHERE \"date_s_of_return\"='July 2008';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"previous_winners\" (\n \"year\" real,\n \"mens_singles\" text,\n \"womens_singles\" text,\n \"mens_doubles\" text,\n \"womens_doubles\" text,\n \"mixed_doubles\" text\n);\n\nQuestion: Who are the mens doubles and womens singles is wang shixian?"
},
{
"role": "assistant",
"content": "SELECT \"mens_doubles\" FROM \"previous_winners\" WHERE \"womens_singles\"='Wang Shixian';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"previous_winners\" (\n \"year\" real,\n \"mens_singles\" text,\n \"womens_singles\" text,\n \"mens_doubles\" text,\n \"womens_doubles\" text,\n \"mixed_doubles\" text\n);\n\nQuestion: Who is the mens singles and womens singlses is wang shixian?"
},
{
"role": "assistant",
"content": "SELECT \"mens_singles\" FROM \"previous_winners\" WHERE \"womens_singles\"='Wang Shixian';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"previous_winners\" (\n \"year\" real,\n \"mens_singles\" text,\n \"womens_singles\" text,\n \"mens_doubles\" text,\n \"womens_doubles\" text,\n \"mixed_doubles\" text\n);\n\nQuestion: Who are the mens doubles and and mens singles is lee hyun-il?"
},
{
"role": "assistant",
"content": "SELECT \"mens_doubles\" FROM \"previous_winners\" WHERE \"mens_singles\"='Lee Hyun-il';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"previous_winners\" (\n \"year\" real,\n \"mens_singles\" text,\n \"womens_singles\" text,\n \"mens_doubles\" text,\n \"womens_doubles\" text,\n \"mixed_doubles\" text\n);\n\nQuestion: Who are the mens singles and womens singles with sun yu?"
},
{
"role": "assistant",
"content": "SELECT \"mens_singles\" FROM \"previous_winners\" WHERE \"womens_singles\"='Sun Yu';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"average_chart\" (\n \"rank_by_average\" real,\n \"competition_finish\" real,\n \"couple\" text,\n \"total\" real,\n \"number_of_dances\" real,\n \"average\" text\n);\n\nQuestion: what is the highest number where people got done at 31.1"
},
{
"role": "assistant",
"content": "SELECT MAX(\"competition_finish\") FROM \"average_chart\" WHERE \"average\"='31.1';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"average_chart\" (\n \"rank_by_average\" real,\n \"competition_finish\" real,\n \"couple\" text,\n \"total\" real,\n \"number_of_dances\" real,\n \"average\" text\n);\n\nQuestion: who danced 11 and finished at more than a 2.0"
},
{
"role": "assistant",
"content": "SELECT \"couple\" FROM \"average_chart\" WHERE \"number_of_dances\"=11 AND \"competition_finish\">2.0;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"average_chart\" (\n \"rank_by_average\" real,\n \"competition_finish\" real,\n \"couple\" text,\n \"total\" real,\n \"number_of_dances\" real,\n \"average\" text\n);\n\nQuestion: tell the competitions where the mean is 1"
},
{
"role": "assistant",
"content": "SELECT \"average\" FROM \"average_chart\" WHERE \"number_of_dances\"=1;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"average_chart\" (\n \"rank_by_average\" real,\n \"competition_finish\" real,\n \"couple\" text,\n \"total\" real,\n \"number_of_dances\" real,\n \"average\" text\n);\n\nQuestion: tell the mean of the times competition for the 7 jigs"
},
{
"role": "assistant",
"content": "SELECT \"rank_by_average\" FROM \"average_chart\" WHERE \"number_of_dances\"=7;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"average_chart\" (\n \"rank_by_average\" real,\n \"competition_finish\" real,\n \"couple\" text,\n \"total\" real,\n \"number_of_dances\" real,\n \"average\" text\n);\n\nQuestion: how many turns were completed to make a mean of 34.0"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"number_of_dances\") FROM \"average_chart\" WHERE \"average\"='34.0';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table_a_fik_specifications_for_competiti\" (\n \"specification\" text,\n \"gender\" text,\n \"junior_high_school_12_15_yrs\" text,\n \"senior_high_school_15_18_yrs\" text,\n \"university_students_and_adults_18yrs\" text\n);\n\nQuestion: What is the gender of the junior high school is 24mm?"
},
{
"role": "assistant",
"content": "SELECT \"gender\" FROM \"table_a_fik_specifications_for_competiti\" WHERE \"junior_high_school_12_15_yrs\"='24mm';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table_a_fik_specifications_for_competiti\" (\n \"specification\" text,\n \"gender\" text,\n \"junior_high_school_12_15_yrs\" text,\n \"senior_high_school_15_18_yrs\" text,\n \"university_students_and_adults_18yrs\" text\n);\n\nQuestion: What amount of the university students and adults ehre the the senior high school is 26mm?"
},
{
"role": "assistant",
"content": "SELECT \"university_students_and_adults_18yrs\" FROM \"table_a_fik_specifications_for_competiti\" WHERE \"senior_high_school_15_18_yrs\"='26mm';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table_a_fik_specifications_for_competiti\" (\n \"specification\" text,\n \"gender\" text,\n \"junior_high_school_12_15_yrs\" text,\n \"senior_high_school_15_18_yrs\" text,\n \"university_students_and_adults_18yrs\" text\n);\n\nQuestion: What amount of senior high school where junior high school is 114cm?"
},
{
"role": "assistant",
"content": "SELECT \"senior_high_school_15_18_yrs\" FROM \"table_a_fik_specifications_for_competiti\" WHERE \"junior_high_school_12_15_yrs\"='114cm';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table_a_fik_specifications_for_competiti\" (\n \"specification\" text,\n \"gender\" text,\n \"junior_high_school_12_15_yrs\" text,\n \"senior_high_school_15_18_yrs\" text,\n \"university_students_and_adults_18yrs\" text\n);\n\nQuestion: What is the specification where senior high school is 25mm?"
},
{
"role": "assistant",
"content": "SELECT \"specification\" FROM \"table_a_fik_specifications_for_competiti\" WHERE \"senior_high_school_15_18_yrs\"='25mm';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table_a_fik_specifications_for_competiti\" (\n \"specification\" text,\n \"gender\" text,\n \"junior_high_school_12_15_yrs\" text,\n \"senior_high_school_15_18_yrs\" text,\n \"university_students_and_adults_18yrs\" text\n);\n\nQuestion: What amount is the junior high school where the gender is male and the specification is minimum diameter of sakigawa?"
},
{
"role": "assistant",
"content": "SELECT \"junior_high_school_12_15_yrs\" FROM \"table_a_fik_specifications_for_competiti\" WHERE \"gender\"='Male' AND \"specification\"='Minimum diameter of sakigawa';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"table_a_fik_specifications_for_competiti\" (\n \"specification\" text,\n \"gender\" text,\n \"junior_high_school_12_15_yrs\" text,\n \"senior_high_school_15_18_yrs\" text,\n \"university_students_and_adults_18yrs\" text\n);\n\nQuestion: What is the gender of senior high school 26mm?"
},
{
"role": "assistant",
"content": "SELECT \"gender\" FROM \"table_a_fik_specifications_for_competiti\" WHERE \"senior_high_school_15_18_yrs\"='26mm';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: What was the score of the game when the team was 1-2?"
},
{
"role": "assistant",
"content": "SELECT \"score\" FROM \"game_log\" WHERE \"record\"='1-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 \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: Who had the high assists against charlotte?"
},
{
"role": "assistant",
"content": "SELECT \"high_assists\" FROM \"game_log\" WHERE \"team\"='Charlotte';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: How many leading scorers were there in the game against Utah?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"high_points\") FROM \"game_log\" WHERE \"team\"='Utah';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: how many\u00a0location attendance\u00a0with\u00a0team\u00a0being charlotte"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"location_attendance\") FROM \"game_log\" WHERE \"team\"='Charlotte';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: what's the\u00a0game\u00a0with\u00a0date\u00a0being march 7"
},
{
"role": "assistant",
"content": "SELECT \"game\" FROM \"game_log\" WHERE \"date\"='March 7';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: what's the\u00a0date\u00a0with\u00a0game\u00a0being 72"
},
{
"role": "assistant",
"content": "SELECT \"date\" FROM \"game_log\" WHERE \"game\"=72;"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: how many\u00a0high assbeingts\u00a0with\u00a0score\u00a0being l 90\u201398 (ot)"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"high_assists\") FROM \"game_log\" WHERE \"score\"='L 90\u201398 (OT)';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: who is the the\u00a0high rebounds\u00a0with\u00a0team\u00a0being vancouver"
},
{
"role": "assistant",
"content": "SELECT \"high_rebounds\" FROM \"game_log\" WHERE \"team\"='Vancouver';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"game_log\" (\n \"game\" real,\n \"date\" text,\n \"team\" text,\n \"score\" text,\n \"high_points\" text,\n \"high_rebounds\" text,\n \"high_assists\" text,\n \"location_attendance\" text,\n \"record\" text\n);\n\nQuestion: How many pairs of numbers are under record on April 12?"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"record\") FROM \"game_log\" WHERE \"date\"='April 12';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2009_2010_table\" (\n \"club\" text,\n \"played\" text,\n \"won\" text,\n \"drawn\" text,\n \"lost\" text,\n \"points_for\" text,\n \"points_against\" text,\n \"tries_for\" text,\n \"tries_against\" text,\n \"try_bonus\" text,\n \"losing_bonus\" text,\n \"points\" text\n);\n\nQuestion: Name total number of won for tries for 92"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"won\") FROM \"2009_2010_table\" WHERE \"tries_for\"='92';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2009_2010_table\" (\n \"club\" text,\n \"played\" text,\n \"won\" text,\n \"drawn\" text,\n \"lost\" text,\n \"points_for\" text,\n \"points_against\" text,\n \"tries_for\" text,\n \"tries_against\" text,\n \"try_bonus\" text,\n \"losing_bonus\" text,\n \"points\" text\n);\n\nQuestion: Name the club when tries for is 83"
},
{
"role": "assistant",
"content": "SELECT \"club\" FROM \"2009_2010_table\" WHERE \"tries_for\"='83';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2009_2010_table\" (\n \"club\" text,\n \"played\" text,\n \"won\" text,\n \"drawn\" text,\n \"lost\" text,\n \"points_for\" text,\n \"points_against\" text,\n \"tries_for\" text,\n \"tries_against\" text,\n \"try_bonus\" text,\n \"losing_bonus\" text,\n \"points\" text\n);\n\nQuestion: Name the try bonus for kenfig hill rfc"
},
{
"role": "assistant",
"content": "SELECT \"try_bonus\" FROM \"2009_2010_table\" WHERE \"club\"='Kenfig Hill RFC';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2009_2010_table\" (\n \"club\" text,\n \"played\" text,\n \"won\" text,\n \"drawn\" text,\n \"lost\" text,\n \"points_for\" text,\n \"points_against\" text,\n \"tries_for\" text,\n \"tries_against\" text,\n \"try_bonus\" text,\n \"losing_bonus\" text,\n \"points\" text\n);\n\nQuestion: Name the tries against for played 22 and points against of 183"
},
{
"role": "assistant",
"content": "SELECT \"tries_against\" FROM \"2009_2010_table\" WHERE \"played\"='22' AND \"points_against\"='183';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2009_2010_table\" (\n \"club\" text,\n \"played\" text,\n \"won\" text,\n \"drawn\" text,\n \"lost\" text,\n \"points_for\" text,\n \"points_against\" text,\n \"tries_for\" text,\n \"tries_against\" text,\n \"try_bonus\" text,\n \"losing_bonus\" text,\n \"points\" text\n);\n\nQuestion: Name the total number of points for when try bonus is 10"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"points_for\") FROM \"2009_2010_table\" WHERE \"try_bonus\"='10';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2009_2010_table\" (\n \"club\" text,\n \"played\" text,\n \"won\" text,\n \"drawn\" text,\n \"lost\" text,\n \"points_for\" text,\n \"points_against\" text,\n \"tries_for\" text,\n \"tries_against\" text,\n \"try_bonus\" text,\n \"losing_bonus\" text,\n \"points\" text\n);\n\nQuestion: Name the number of won for maesteg harlequins rfc"
},
{
"role": "assistant",
"content": "SELECT COUNT(\"won\") FROM \"2009_2010_table\" WHERE \"club\"='Maesteg Harlequins RFC';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2009_2010_table\" (\n \"club\" text,\n \"played\" text,\n \"won\" text,\n \"drawn\" text,\n \"lost\" text,\n \"points_for\" text,\n \"points_against\" text,\n \"tries_for\" text,\n \"tries_against\" text,\n \"try_bonus\" text,\n \"losing_bonus\" text,\n \"points\" text\n);\n\nQuestion: What amount had all played that lost were 8?"
},
{
"role": "assistant",
"content": "SELECT \"played\" FROM \"2009_2010_table\" WHERE \"lost\"='8';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2009_2010_table\" (\n \"club\" text,\n \"played\" text,\n \"won\" text,\n \"drawn\" text,\n \"lost\" text,\n \"points_for\" text,\n \"points_against\" text,\n \"tries_for\" text,\n \"tries_against\" text,\n \"try_bonus\" text,\n \"losing_bonus\" text,\n \"points\" text\n);\n\nQuestion: what is the name of the club where drawn is 1 and lost is 10?"
},
{
"role": "assistant",
"content": "SELECT \"club\" FROM \"2009_2010_table\" WHERE \"drawn\"='1' AND \"lost\"='10';"
}
]
|
[
{
"role": "system",
"content": "You are an expert SQL query generator. Only output valid SQL."
},
{
"role": "user",
"content": "### Database Schema\nCREATE TABLE \"2009_2010_table\" (\n \"club\" text,\n \"played\" text,\n \"won\" text,\n \"drawn\" text,\n \"lost\" text,\n \"points_for\" text,\n \"points_against\" text,\n \"tries_for\" text,\n \"tries_against\" text,\n \"try_bonus\" text,\n \"losing_bonus\" text,\n \"points\" text\n);\n\nQuestion: what are the tries where the game was lost by 4?"
},
{
"role": "assistant",
"content": "SELECT \"tries_against\" FROM \"2009_2010_table\" WHERE \"lost\"='4';"
}
]
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.