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 \"regular_season\" (\n \"game\" real,\n \"date\" text,\n \"opponent\" 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 a high rebound where the associated record is 11-13?" }, { "role": "assistant", "content": "SELECT \"high_rebounds\" FROM \"regular_season\" WHERE \"record\"='11-13';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"game\" real,\n \"date\" text,\n \"opponent\" 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: On July 8, what was the score?" }, { "role": "assistant", "content": "SELECT \"score\" FROM \"regular_season\" WHERE \"date\"='July 8';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"game\" real,\n \"date\" text,\n \"opponent\" 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 was the oppenent what the score was L 68-60?" }, { "role": "assistant", "content": "SELECT \"opponent\" FROM \"regular_season\" WHERE \"score\"='L 68-60';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"2009_nbl_ladder_championship_round\" (\n \"rank\" real,\n \"team\" text,\n \"played\" real,\n \"win\" real,\n \"loss\" real,\n \"last_5\" text,\n \"streak\" text,\n \"pf_per_game\" text,\n \"pa_per_game\" text,\n \"pd_per_game\" text,\n \"winning_pct\" text\n);\n\nQuestion: what is the winning % whre the last 5 is 3-2 and the streak is l1?" }, { "role": "assistant", "content": "SELECT \"winning_pct\" FROM \"2009_nbl_ladder_championship_round\" WHERE \"last_5\"='3-2' AND \"streak\"='L1';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"game\" real,\n \"date\" text,\n \"opponent\" 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: If high assists are under Canty (6) how much would the record be?" }, { "role": "assistant", "content": "SELECT \"record\" FROM \"regular_season\" WHERE \"high_assists\"='Canty (6)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"game\" real,\n \"date\" text,\n \"opponent\" 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: If the score is 62-70, what are the high points?" }, { "role": "assistant", "content": "SELECT \"high_points\" FROM \"regular_season\" WHERE \"score\"='62-70';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"game\" real,\n \"date\" text,\n \"opponent\" 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: On which date was the location/attendance UIC Pavilion 3,829 respectively?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"regular_season\" WHERE \"location_attendance\"='UIC Pavilion 3,829';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"game\" real,\n \"date\" text,\n \"opponent\" 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: On which date is high assists Dupree (6)?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"regular_season\" WHERE \"high_assists\"='Dupree (6)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"investment_and_financing\" (\n \"department\" text,\n \"projects\" real,\n \"municipalities\" real,\n \"farmers\" real,\n \"irrigated_ha\" real,\n \"bid_pronar_investment_us\" text,\n \"local_investment_us\" text,\n \"total\" text\n);\n\nQuestion: What was the local investment (in $) in the projects of the department with $912,185 BID/PRONAR investment?" }, { "role": "assistant", "content": "SELECT \"local_investment_us\" FROM \"investment_and_financing\" WHERE \"bid_pronar_investment_us\"='912,185';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"investment_and_financing\" (\n \"department\" text,\n \"projects\" real,\n \"municipalities\" real,\n \"farmers\" real,\n \"irrigated_ha\" real,\n \"bid_pronar_investment_us\" text,\n \"local_investment_us\" text,\n \"total\" text\n);\n\nQuestion: How many farmers were included by the department with 32 projects?" }, { "role": "assistant", "content": "SELECT MAX(\"farmers\") FROM \"investment_and_financing\" WHERE \"projects\"=32;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"investment_and_financing\" (\n \"department\" text,\n \"projects\" real,\n \"municipalities\" real,\n \"farmers\" real,\n \"irrigated_ha\" real,\n \"bid_pronar_investment_us\" text,\n \"local_investment_us\" text,\n \"total\" text\n);\n\nQuestion: What department irrigated 2170 Ha?" }, { "role": "assistant", "content": "SELECT \"department\" FROM \"investment_and_financing\" WHERE \"irrigated_ha\"=2170;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"investment_and_financing\" (\n \"department\" text,\n \"projects\" real,\n \"municipalities\" real,\n \"farmers\" real,\n \"irrigated_ha\" real,\n \"bid_pronar_investment_us\" text,\n \"local_investment_us\" text,\n \"total\" text\n);\n\nQuestion: What was the BID/PRONAR investment (in $) in the department that included 1326 farmers in its projects?" }, { "role": "assistant", "content": "SELECT \"bid_pronar_investment_us\" FROM \"investment_and_financing\" WHERE \"farmers\"=1326;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"investment_and_financing\" (\n \"department\" text,\n \"projects\" real,\n \"municipalities\" real,\n \"farmers\" real,\n \"irrigated_ha\" real,\n \"bid_pronar_investment_us\" text,\n \"local_investment_us\" text,\n \"total\" text\n);\n\nQuestion: What was the department that got $626,798 in local investments?" }, { "role": "assistant", "content": "SELECT \"department\" FROM \"investment_and_financing\" WHERE \"local_investment_us\"='626,798';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"game\" real,\n \"date\" text,\n \"opponent\" 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 number was the game resulting in a 5-11 record?" }, { "role": "assistant", "content": "SELECT MIN(\"game\") FROM \"regular_season\" WHERE \"record\"='5-11';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"game\" real,\n \"date\" text,\n \"opponent\" 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 high assists are listed for the game with a score of 68-60?" }, { "role": "assistant", "content": "SELECT COUNT(\"high_assists\") FROM \"regular_season\" WHERE \"score\"='68-60';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"regular_season\" (\n \"game\" real,\n \"date\" text,\n \"opponent\" 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: In the game resulting in a 5-11 record, who scored the high rebounds?" }, { "role": "assistant", "content": "SELECT \"high_rebounds\" FROM \"regular_season\" WHERE \"record\"='5-11';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"january\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: Who was the opponent of the game with final score won 4-1?" }, { "role": "assistant", "content": "SELECT \"opponent\" FROM \"january\" WHERE \"result\"='Won 4-1';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"january\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: What was the attendance at the game where Neil Liddiard was Man of the Match?" }, { "role": "assistant", "content": "SELECT MIN(\"attendance\") FROM \"january\" WHERE \"man_of_the_match\"='Neil Liddiard';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"january\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: What was the venue of the game that was lost 3-4?" }, { "role": "assistant", "content": "SELECT \"venue\" FROM \"january\" WHERE \"result\"='Lost 3-4';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"january\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: What is the venue of the game with Man of the Match Vaclav Zavoral?" }, { "role": "assistant", "content": "SELECT \"venue\" FROM \"january\" WHERE \"man_of_the_match\"='Vaclav Zavoral';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"january\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: How many attendance figures are given for the game where the final score was lost 5-3?" }, { "role": "assistant", "content": "SELECT COUNT(\"attendance\") FROM \"january\" WHERE \"result\"='Lost 5-3';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"october\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: Name the opponent for 4th" }, { "role": "assistant", "content": "SELECT \"opponent\" FROM \"october\" WHERE \"date\"='4th';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"october\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: Name the venue for 19th date" }, { "role": "assistant", "content": "SELECT \"venue\" FROM \"october\" WHERE \"date\"='19th';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"october\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: Name the result for lukas smital and home" }, { "role": "assistant", "content": "SELECT \"result\" FROM \"october\" WHERE \"man_of_the_match\"='Lukas Smital' AND \"venue\"='Home';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"october\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: Name the man of the match for 24th" }, { "role": "assistant", "content": "SELECT \"man_of_the_match\" FROM \"october\" WHERE \"date\"='24th';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"october\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: Name the man of the maatch for sheffield scimitars" }, { "role": "assistant", "content": "SELECT \"man_of_the_match\" FROM \"october\" WHERE \"opponent\"='Sheffield Scimitars';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"november\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: On the 19th, where was the venue?" }, { "role": "assistant", "content": "SELECT \"venue\" FROM \"november\" WHERE \"date\"='19th';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"november\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: What was the total attendance during the home game against the Swindon Wildcats?" }, { "role": "assistant", "content": "SELECT \"attendance\" FROM \"november\" WHERE \"opponent\"='Swindon Wildcats' AND \"venue\"='Home';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"november\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: On what day was Stuart Potts the Man of the Match?" }, { "role": "assistant", "content": "SELECT \"date\" FROM \"november\" WHERE \"man_of_the_match\"='Stuart Potts';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"november\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: At what venue did Alex Mettam/Mark Williams be named Man of the Match?" }, { "role": "assistant", "content": "SELECT \"venue\" FROM \"november\" WHERE \"man_of_the_match\"='Alex Mettam/Mark Williams';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"december\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: How many dates did David Savage get man of the match?" }, { "role": "assistant", "content": "SELECT COUNT(\"date\") FROM \"december\" WHERE \"man_of_the_match\"='David Savage';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"december\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: When the attendance was 1568, who was man of the match?" }, { "role": "assistant", "content": "SELECT \"man_of_the_match\" FROM \"december\" WHERE \"attendance\"=1568;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"december\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" real,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: Who was the man of the match when they lost 2-4?" }, { "role": "assistant", "content": "SELECT \"man_of_the_match\" FROM \"december\" WHERE \"result\"='Lost 2-4';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"february\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" text,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: what was the competitoin where the opponent is sheffield scimitars?" }, { "role": "assistant", "content": "SELECT \"competition\" FROM \"february\" WHERE \"opponent\"='Sheffield Scimitars';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"february\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" text,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: where was the venue where the attendance was 702?" }, { "role": "assistant", "content": "SELECT \"venue\" FROM \"february\" WHERE \"attendance\"='702';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"february\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" text,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: what was the venue where the date was the 22nd?" }, { "role": "assistant", "content": "SELECT \"venue\" FROM \"february\" WHERE \"date\"='22nd';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"february\" (\n \"date\" text,\n \"opponent\" text,\n \"venue\" text,\n \"result\" text,\n \"attendance\" text,\n \"competition\" text,\n \"man_of_the_match\" text\n);\n\nQuestion: who was the opponent where the date was the 21st?" }, { "role": "assistant", "content": "SELECT \"opponent\" FROM \"february\" WHERE \"date\"='21st';" } ]
[ { "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 is the score for Milwaukee? " }, { "role": "assistant", "content": "SELECT \"score\" FROM \"game_log\" WHERE \"team\"='Milwaukee';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_17121262_10\" (\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 record against Washington?" }, { "role": "assistant", "content": "SELECT COUNT(\"record\") FROM \"table1_17121262_10\" WHERE \"team\"='Washington';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"communities\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: If the census ranking is 231 of 5,008, what was the population?" }, { "role": "assistant", "content": "SELECT \"population\" FROM \"communities\" WHERE \"census_ranking\"='231 of 5,008';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"communities\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: If the area is 59.73, what is the official name?" }, { "role": "assistant", "content": "SELECT \"official_name\" FROM \"communities\" WHERE \"area_km_2\"='59.73';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"communities\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: If the census ranking is 693 of 5,008, what is the status?" }, { "role": "assistant", "content": "SELECT \"status\" FROM \"communities\" WHERE \"census_ranking\"='693 of 5,008';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"communities\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: With the official name Quispamsis, what is the census ranking?" }, { "role": "assistant", "content": "SELECT \"census_ranking\" FROM \"communities\" WHERE \"official_name\"='Quispamsis';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"communities\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: What was the population for census ranking 782 of 5,008?" }, { "role": "assistant", "content": "SELECT \"population\" FROM \"communities\" WHERE \"census_ranking\"='782 of 5,008';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"communities\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: If the area is 34.73, what is the census ranking?" }, { "role": "assistant", "content": "SELECT \"census_ranking\" FROM \"communities\" WHERE \"area_km_2\"='34.73';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"parishes\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: What are the census ranking(s) for a population of 284?" }, { "role": "assistant", "content": "SELECT \"census_ranking\" FROM \"parishes\" WHERE \"population\"=284;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"parishes\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: What are the census ranking(s) that have an area of 369.25 km2?" }, { "role": "assistant", "content": "SELECT \"census_ranking\" FROM \"parishes\" WHERE \"area_km_2\"='369.25';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"parishes\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: What is the population that has an area of 715.58?" }, { "role": "assistant", "content": "SELECT \"population\" FROM \"parishes\" WHERE \"area_km_2\"='715.58';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"parishes\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: What are that status(es) of saint-jacques?" }, { "role": "assistant", "content": "SELECT \"status\" FROM \"parishes\" WHERE \"official_name\"='Saint-Jacques';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"parishes\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: What are the area(s) (km2) for saint-joseph?" }, { "role": "assistant", "content": "SELECT \"area_km_2\" FROM \"parishes\" WHERE \"official_name\"='Saint-Joseph';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"parishes\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: What rank is the parish with 482.81 km^2?" }, { "role": "assistant", "content": "SELECT \"census_ranking\" FROM \"parishes\" WHERE \"area_km_2\"='482.81';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"parishes\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: What status doe the area with a census ranking of 2,290 of 5,008 have?" }, { "role": "assistant", "content": "SELECT \"status\" FROM \"parishes\" WHERE \"census_ranking\"='2,290 of 5,008';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"parishes\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: How many statuses are listed for the parish officially named Gagetown?" }, { "role": "assistant", "content": "SELECT COUNT(\"status\") FROM \"parishes\" WHERE \"official_name\"='Gagetown';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"parishes\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: What is Petersville's census ranking?" }, { "role": "assistant", "content": "SELECT \"census_ranking\" FROM \"parishes\" WHERE \"official_name\"='Petersville';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"communities\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: What is the population of each community with city status?" }, { "role": "assistant", "content": "SELECT \"population\" FROM \"communities\" WHERE \"status\"='City';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"communities\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: What is the name of the community with an area of 30.75 sq. km.?" }, { "role": "assistant", "content": "SELECT \"official_name\" FROM \"communities\" WHERE \"area_km_2\"='30.75';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"communities\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: What is the area of the community with a population of 1209?" }, { "role": "assistant", "content": "SELECT \"area_km_2\" FROM \"communities\" WHERE \"population\"=1209;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"communities\" (\n \"official_name\" text,\n \"status\" text,\n \"area_km_2\" text,\n \"population\" real,\n \"census_ranking\" text\n);\n\nQuestion: How many population values are listed for the community with an area of 10.25 sq.km.?" }, { "role": "assistant", "content": "SELECT COUNT(\"population\") FROM \"communities\" WHERE \"area_km_2\"='10.25';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_171320_3\" (\n \"dvd_name\" text,\n \"ep_num\" real,\n \"region_1\" text,\n \"region_2_scandinavia\" text,\n \"region_2_uk\" text,\n \"region_4\" text,\n \"special_features\" text\n);\n\nQuestion: Name the region 1 where region 4 for april 2, 2009" }, { "role": "assistant", "content": "SELECT \"region_1\" FROM \"table1_171320_3\" WHERE \"region_4\"='April 2, 2009';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_171320_3\" (\n \"dvd_name\" text,\n \"ep_num\" real,\n \"region_1\" text,\n \"region_2_scandinavia\" text,\n \"region_2_uk\" text,\n \"region_4\" text,\n \"special_features\" text\n);\n\nQuestion: Name the region 1 for episode number 13" }, { "role": "assistant", "content": "SELECT \"region_1\" FROM \"table1_171320_3\" WHERE \"ep_num\"=13;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_17152787_3\" (\n \"series_num\" real,\n \"season_num\" real,\n \"title\" text,\n \"directed_by\" text,\n \"original_air_date\" text,\n \"prod_code\" real\n);\n\nQuestion: Who directed the episode titled \"Episode 19\"?" }, { "role": "assistant", "content": "SELECT \"directed_by\" FROM \"table1_17152787_3\" WHERE \"title\"='\\\"Episode 19\\\"';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_17152787_3\" (\n \"series_num\" real,\n \"season_num\" real,\n \"title\" text,\n \"directed_by\" text,\n \"original_air_date\" text,\n \"prod_code\" real\n);\n\nQuestion: How many episodes have the season number of 1?" }, { "role": "assistant", "content": "SELECT COUNT(\"series_num\") FROM \"table1_17152787_3\" WHERE \"season_num\"=1;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"language_s\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: Who was the director of the film with the original title of \"The Patience Stone\"? " }, { "role": "assistant", "content": "SELECT \"director\" FROM \"submissions\" WHERE \"original_title\"='The Patience Stone';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"language_s\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: For what ceremony was \"Fire Dancer\" not nominated? " }, { "role": "assistant", "content": "SELECT \"year_ceremony\" FROM \"submissions\" WHERE \"original_title\"='Fire Dancer';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"language_s\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What name was used for nomination for the film with an original title of \"The Black Tulip\"? " }, { "role": "assistant", "content": "SELECT \"film_title_used_in_nomination\" FROM \"submissions\" WHERE \"original_title\"='The Black Tulip';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"language_s\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What languages were spoken in the film \"FireDancer\"?" }, { "role": "assistant", "content": "SELECT \"language_s\" FROM \"submissions\" WHERE \"film_title_used_in_nomination\"='FireDancer';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"submissions\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"language_s\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: Who was the director of the film with an original title of \"16 Days in Afghanistan\"? " }, { "role": "assistant", "content": "SELECT \"director\" FROM \"submissions\" WHERE \"original_title\"='16 Days in Afghanistan';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tree_level_packages\" (\n \"name\" text,\n \"model\" text,\n \"max_fs\" text,\n \"tested_fs\" text,\n \"short_description\" text,\n \"publication\" text,\n \"method\" text,\n \"output\" text,\n \"status\" text\n);\n\nQuestion: what is the model where the method is ha?" }, { "role": "assistant", "content": "SELECT \"model\" FROM \"tree_level_packages\" WHERE \"method\"='HA';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tree_level_packages\" (\n \"name\" text,\n \"model\" text,\n \"max_fs\" text,\n \"tested_fs\" text,\n \"short_description\" text,\n \"publication\" text,\n \"method\" text,\n \"output\" text,\n \"status\" text\n);\n\nQuestion: what is the total number of model wehre the status is named geneva?" }, { "role": "assistant", "content": "SELECT COUNT(\"model\") FROM \"tree_level_packages\" WHERE \"status\"='Status' AND \"name\"='GenEva';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tree_level_packages\" (\n \"name\" text,\n \"model\" text,\n \"max_fs\" text,\n \"tested_fs\" text,\n \"short_description\" text,\n \"publication\" text,\n \"method\" text,\n \"output\" text,\n \"status\" text\n);\n\nQuestion: what is the max fs where the status is status and the method is method?" }, { "role": "assistant", "content": "SELECT \"max_fs\" FROM \"tree_level_packages\" WHERE \"status\"='Status' AND \"method\"='Method';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"tree_level_packages\" (\n \"name\" text,\n \"model\" text,\n \"max_fs\" text,\n \"tested_fs\" text,\n \"short_description\" text,\n \"publication\" text,\n \"method\" text,\n \"output\" text,\n \"status\" text\n);\n\nQuestion: what ist he output where the short description is massive?" }, { "role": "assistant", "content": "SELECT \"output\" FROM \"tree_level_packages\" WHERE \"short_description\"='massive';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_17156199_1\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What was the nominated film title of \u09b6\u09cd\u09af\u09be\u09ae\u09b2 \u099b\u09be\u09af\u09bc\u09be (shyamol chhaya)?" }, { "role": "assistant", "content": "SELECT \"film_title_used_in_nomination\" FROM \"table1_17156199_1\" WHERE \"original_title\"='\u09b6\u09cd\u09af\u09be\u09ae\u09b2 \u099b\u09be\u09af\u09bc\u09be (Shyamol Chhaya)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_17156199_1\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: What year and ceremony was the original title \u09ac\u09c3\u09a4\u09cd\u09a4\u09c7\u09b0 \u09ac\u09be\u0987\u09b0\u09c7 (britter baire)?" }, { "role": "assistant", "content": "SELECT \"year_ceremony\" FROM \"table1_17156199_1\" WHERE \"original_title\"='\u09ac\u09c3\u09a4\u09cd\u09a4\u09c7\u09b0 \u09ac\u09be\u0987\u09b0\u09c7 (Britter Baire)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_17156199_1\" (\n \"year_ceremony\" text,\n \"film_title_used_in_nomination\" text,\n \"original_title\" text,\n \"director\" text,\n \"result\" text\n);\n\nQuestion: How many years was the original title was \u09b8\u09cd\u09ac\u09aa\u09cd\u09a8\u09a1\u09be\u09a8\u09be\u09af\u09bc (swopnodanay)?" }, { "role": "assistant", "content": "SELECT COUNT(\"year_ceremony\") FROM \"table1_17156199_1\" WHERE \"original_title\"='\u09b8\u09cd\u09ac\u09aa\u09cd\u09a8\u09a1\u09be\u09a8\u09be\u09af\u09bc (Swopnodanay)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"former_members\" (\n \"institution\" text,\n \"location\" text,\n \"founded\" real,\n \"type\" text,\n \"enrollment\" real,\n \"nickname\" text,\n \"joined\" real,\n \"left\" real,\n \"current_conference\" text\n);\n\nQuestion: what is the nickname founded in 1902?" }, { "role": "assistant", "content": "SELECT \"nickname\" FROM \"former_members\" WHERE \"founded\"=1902;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"former_members\" (\n \"institution\" text,\n \"location\" text,\n \"founded\" real,\n \"type\" text,\n \"enrollment\" real,\n \"nickname\" text,\n \"joined\" real,\n \"left\" real,\n \"current_conference\" text\n);\n\nQuestion: where is the enrollment 4259?" }, { "role": "assistant", "content": "SELECT \"location\" FROM \"former_members\" WHERE \"enrollment\"=4259;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"former_members\" (\n \"institution\" text,\n \"location\" text,\n \"founded\" real,\n \"type\" text,\n \"enrollment\" real,\n \"nickname\" text,\n \"joined\" real,\n \"left\" real,\n \"current_conference\" text\n);\n\nQuestion: what is the year union university was founded?" }, { "role": "assistant", "content": "SELECT \"founded\" FROM \"former_members\" WHERE \"institution\"='Union University';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"population\" (\n \"province\" text,\n \"south_asians_2001\" real,\n \"pct_2001\" text,\n \"south_asians_2011\" real,\n \"pct_2011\" text\n);\n\nQuestion: What was the percentage in Manitoba in 2011?" }, { "role": "assistant", "content": "SELECT \"pct_2011\" FROM \"population\" WHERE \"province\"='Manitoba';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"population\" (\n \"province\" text,\n \"south_asians_2001\" real,\n \"pct_2001\" text,\n \"south_asians_2011\" real,\n \"pct_2011\" text\n);\n\nQuestion: Which province had population of 210295 South Asians in 2001?" }, { "role": "assistant", "content": "SELECT \"province\" FROM \"population\" WHERE \"south_asians_2001\"=210295;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"population\" (\n \"province\" text,\n \"south_asians_2001\" real,\n \"pct_2001\" text,\n \"south_asians_2011\" real,\n \"pct_2011\" text\n);\n\nQuestion: What was the South Asian population in Nova Scotia in 2001?" }, { "role": "assistant", "content": "SELECT \"south_asians_2001\" FROM \"population\" WHERE \"province\"='Nova Scotia';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"population\" (\n \"province\" text,\n \"south_asians_2001\" real,\n \"pct_2001\" text,\n \"south_asians_2011\" real,\n \"pct_2011\" text\n);\n\nQuestion: What was the percentage in 2011 of the province that had 2.4% population in 2001?" }, { "role": "assistant", "content": "SELECT \"pct_2011\" FROM \"population\" WHERE \"pct_2001\"='2.4%';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"population\" (\n \"province\" text,\n \"south_asians_2001\" real,\n \"pct_2001\" text,\n \"south_asians_2011\" real,\n \"pct_2011\" text\n);\n\nQuestion: How many figures are given for total number of South Asians in 2001 for the area where they were 4.4% of population in 2011?" }, { "role": "assistant", "content": "SELECT COUNT(\"south_asians_2001\") FROM \"population\" WHERE \"pct_2011\"='4.4%';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"immigration\" (\n \"year\" real,\n \"indians_admitted\" real,\n \"pakistanis_admitted\" real,\n \"sri_lankans_admitted\" real,\n \"bangladeshis_admitted\" real,\n \"nepalis_admitted\" real\n);\n\nQuestion: How many Indians were admitted in 2001?" }, { "role": "assistant", "content": "SELECT \"indians_admitted\" FROM \"immigration\" WHERE \"year\"=2001;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"immigration\" (\n \"year\" real,\n \"indians_admitted\" real,\n \"pakistanis_admitted\" real,\n \"sri_lankans_admitted\" real,\n \"bangladeshis_admitted\" real,\n \"nepalis_admitted\" real\n);\n\nQuestion: What is the greatest number of Pakistanis admitted to Canada during those times when the number of Nepalis admitted was 627?" }, { "role": "assistant", "content": "SELECT MAX(\"pakistanis_admitted\") FROM \"immigration\" WHERE \"nepalis_admitted\"=627;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"immigration\" (\n \"year\" real,\n \"indians_admitted\" real,\n \"pakistanis_admitted\" real,\n \"sri_lankans_admitted\" real,\n \"bangladeshis_admitted\" real,\n \"nepalis_admitted\" real\n);\n\nQuestion: What is the most number of Indians admitted to Canada when the number of Sri Lankans admitted was 3104?" }, { "role": "assistant", "content": "SELECT MIN(\"indians_admitted\") FROM \"immigration\" WHERE \"sri_lankans_admitted\"=3104;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"seasonal_timeslots_ratings\" (\n \"season\" real,\n \"tv_season\" text,\n \"regular_timeslot_edt\" text,\n \"episode_count\" real,\n \"season_premiere\" text,\n \"season_finale\" text,\n \"rank\" text,\n \"rating\" text\n);\n\nQuestion: Name the number of tv seasons for season finale being may 24, 1994" }, { "role": "assistant", "content": "SELECT COUNT(\"tv_season\") FROM \"seasonal_timeslots_ratings\" WHERE \"season_finale\"='May 24, 1994';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"seasonal_timeslots_ratings\" (\n \"season\" real,\n \"tv_season\" text,\n \"regular_timeslot_edt\" text,\n \"episode_count\" real,\n \"season_premiere\" text,\n \"season_finale\" text,\n \"rank\" text,\n \"rating\" text\n);\n\nQuestion: Name the number of tv seasons for season finale of may 23, 1995" }, { "role": "assistant", "content": "SELECT COUNT(\"tv_season\") FROM \"seasonal_timeslots_ratings\" WHERE \"season_finale\"='May 23, 1995';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"riders\" (\n \"position\" real,\n \"driver_passenger\" text,\n \"equipment\" text,\n \"bike_no\" real,\n \"points\" real\n);\n\nQuestion: Name the driver/passenger for 30" }, { "role": "assistant", "content": "SELECT COUNT(\"driver_passenger\") FROM \"riders\" WHERE \"position\"=30;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"riders\" (\n \"position\" real,\n \"driver_passenger\" text,\n \"equipment\" text,\n \"bike_no\" real,\n \"points\" real\n);\n\nQuestion: Name the max bike number of position for 30" }, { "role": "assistant", "content": "SELECT MAX(\"bike_no\") FROM \"riders\" WHERE \"position\"=30;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"playoffs\" (\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 \"series\" text\n);\n\nQuestion: Who had the most points in game 4?" }, { "role": "assistant", "content": "SELECT \"high_points\" FROM \"playoffs\" WHERE \"game\"=4;" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_17200372_2\" (\n \"departure\" text,\n \"going_to\" text,\n \"calling_at\" text,\n \"arrival\" text,\n \"operator\" text\n);\n\nQuestion: Name the number of going to for thurlby, braceborough spa at departure being 16.50" }, { "role": "assistant", "content": "SELECT COUNT(\"going_to\") FROM \"table1_17200372_2\" WHERE \"calling_at\"='Thurlby, Braceborough Spa' AND \"departure\"='16.50';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"table1_17200372_2\" (\n \"departure\" text,\n \"going_to\" text,\n \"calling_at\" text,\n \"arrival\" text,\n \"operator\" text\n);\n\nQuestion: Name the departure for spalding" }, { "role": "assistant", "content": "SELECT \"departure\" FROM \"table1_17200372_2\" WHERE \"going_to\"='Spalding';" } ]
[ { "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 scored highest points on the game with record 27\u20135" }, { "role": "assistant", "content": "SELECT \"high_points\" FROM \"game_log\" WHERE \"record\"='27\u20135';" } ]
[ { "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 did highest rebounds in the game with score w 105\u201388 (ot)" }, { "role": "assistant", "content": "SELECT \"high_rebounds\" FROM \"game_log\" WHERE \"score\"='W 105\u201388 (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: how many records were made on the game that ended with score w 121\u2013119 (ot)" }, { "role": "assistant", "content": "SELECT COUNT(\"record\") FROM \"game_log\" WHERE \"score\"='W 121\u2013119 (OT)';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"managerial_changes\" (\n \"team\" text,\n \"outgoing_manager\" text,\n \"manner_of_departure\" text,\n \"date_of_vacancy\" text,\n \"replaced_by\" text,\n \"date_of_appointment\" text,\n \"position_in_table\" text\n);\n\nQuestion: What was the team's position when the new manager was Lucas Alcaraz?" }, { "role": "assistant", "content": "SELECT \"position_in_table\" FROM \"managerial_changes\" WHERE \"replaced_by\"='Lucas Alcaraz';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"managerial_changes\" (\n \"team\" text,\n \"outgoing_manager\" text,\n \"manner_of_departure\" text,\n \"date_of_vacancy\" text,\n \"replaced_by\" text,\n \"date_of_appointment\" text,\n \"position_in_table\" text\n);\n\nQuestion: Who replaced outgoing manager Jos\u00e9 \u00c1ngel Ziganda?" }, { "role": "assistant", "content": "SELECT \"replaced_by\" FROM \"managerial_changes\" WHERE \"outgoing_manager\"='Jos\u00e9 \u00c1ngel Ziganda';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"classification\" (\n \"fin_pos\" real,\n \"car_no\" real,\n \"driver\" text,\n \"team\" text,\n \"laps\" real,\n \"time_retired\" text,\n \"grid\" real,\n \"laps_led\" real,\n \"points\" text\n);\n\nQuestion: What grid did the driver who earned 19 points start at?" }, { "role": "assistant", "content": "SELECT \"grid\" FROM \"classification\" WHERE \"points\"='19';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"classification\" (\n \"fin_pos\" real,\n \"car_no\" real,\n \"driver\" text,\n \"team\" text,\n \"laps\" real,\n \"time_retired\" text,\n \"grid\" real,\n \"laps_led\" real,\n \"points\" text\n);\n\nQuestion: Scott Dixon had how many Grid positions?" }, { "role": "assistant", "content": "SELECT COUNT(\"grid\") FROM \"classification\" WHERE \"driver\"='Scott Dixon';" } ]
[ { "role": "system", "content": "You are an expert SQL query generator. Only output valid SQL." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE \"classification\" (\n \"fin_pos\" real,\n \"car_no\" real,\n \"driver\" text,\n \"team\" text,\n \"laps\" real,\n \"time_retired\" text,\n \"grid\" real,\n \"laps_led\" real,\n \"points\" text\n);\n\nQuestion: Car number 15 earned what time?" }, { "role": "assistant", "content": "SELECT \"time_retired\" FROM \"classification\" WHERE \"car_no\"=15;" } ]