text
stringlengths
147
1.06k
source
dict
### INSTRUCTION Who directed the episode written by Matt Ford? ### INPUT CREATE TABLE table_18712423_3 (directed_by VARCHAR, written_by VARCHAR) ### OUTPUT SELECT directed_by FROM table_18712423_3 WHERE written_by = "Matt Ford"
{ "input": "CREATE TABLE table_18712423_3 (directed_by VARCHAR, written_by VARCHAR)", "instruction": "Who directed the episode written by Matt Ford?", "output": "SELECT directed_by FROM table_18712423_3 WHERE written_by = \"Matt Ford\"" }
### INSTRUCTION What is the English title for Ansikte Mot Ansikte? ### INPUT CREATE TABLE table_name_90 (english_title VARCHAR, original_title VARCHAR) ### OUTPUT SELECT english_title FROM table_name_90 WHERE original_title = "ansikte mot ansikte"
{ "input": "CREATE TABLE table_name_90 (english_title VARCHAR, original_title VARCHAR)", "instruction": "What is the English title for Ansikte Mot Ansikte?", "output": "SELECT english_title FROM table_name_90 WHERE original_title = \"ansikte mot ansikte\"" }
### INSTRUCTION Return the name and number of reservations made for each of the rooms. ### INPUT CREATE TABLE Reservations (Room VARCHAR); CREATE TABLE Rooms (roomName VARCHAR, RoomId VARCHAR) ### OUTPUT SELECT T2.roomName, COUNT(*), T1.Room FROM Reservations AS T1 JOIN Rooms AS T2 ON T1.Room = T2.RoomId GROUP BY T1.Room
{ "input": "CREATE TABLE Reservations (Room VARCHAR); CREATE TABLE Rooms (roomName VARCHAR, RoomId VARCHAR)", "instruction": "Return the name and number of reservations made for each of the rooms.", "output": "SELECT T2.roomName, COUNT(*), T1.Room FROM Reservations AS T1 JOIN Rooms AS T2 ON T1.Room = T2.RoomId GROUP BY T1.Room" }
### INSTRUCTION Which winning song had a debut album in progress? ### INPUT CREATE TABLE table_name_32 (winning_song VARCHAR, debut_album VARCHAR) ### OUTPUT SELECT winning_song FROM table_name_32 WHERE debut_album = "in progress"
{ "input": "CREATE TABLE table_name_32 (winning_song VARCHAR, debut_album VARCHAR)", "instruction": "Which winning song had a debut album in progress?", "output": "SELECT winning_song FROM table_name_32 WHERE debut_album = \"in progress\"" }
### INSTRUCTION Which event was the opponent jose carlos oliveira? ### INPUT CREATE TABLE table_name_46 (event VARCHAR, opponent VARCHAR) ### OUTPUT SELECT event FROM table_name_46 WHERE opponent = "jose carlos oliveira"
{ "input": "CREATE TABLE table_name_46 (event VARCHAR, opponent VARCHAR)", "instruction": "Which event was the opponent jose carlos oliveira?", "output": "SELECT event FROM table_name_46 WHERE opponent = \"jose carlos oliveira\"" }
### INSTRUCTION Name the most number in season for leslie hill ### INPUT CREATE TABLE table_25604014_9 (no_in_season INTEGER, directed_by VARCHAR) ### OUTPUT SELECT MAX(no_in_season) FROM table_25604014_9 WHERE directed_by = "Leslie Hill"
{ "input": "CREATE TABLE table_25604014_9 (no_in_season INTEGER, directed_by VARCHAR)", "instruction": "Name the most number in season for leslie hill", "output": "SELECT MAX(no_in_season) FROM table_25604014_9 WHERE directed_by = \"Leslie Hill\"" }
### INSTRUCTION Which Description has a Year of Issue of 1983, and a Thickness of 1.7mm, and a Weight of 3.50grams? ### INPUT CREATE TABLE table_name_8 (description VARCHAR, weight VARCHAR, year_of_issue VARCHAR, thickness VARCHAR) ### OUTPUT SELECT description FROM table_name_8 WHERE year_of_issue = 1983 AND thickness = "1.7mm" AND weight = "3.50grams"
{ "input": "CREATE TABLE table_name_8 (description VARCHAR, weight VARCHAR, year_of_issue VARCHAR, thickness VARCHAR)", "instruction": "Which Description has a Year of Issue of 1983, and a Thickness of 1.7mm, and a Weight of 3.50grams?", "output": "SELECT description FROM table_name_8 WHERE year_of_issue = 1983 AND thickness = \"1.7mm\" AND weight = \"3.50grams\"" }
### INSTRUCTION What's the region for an item on November 10, 2007 that's a cd? ### INPUT CREATE TABLE table_name_91 (region VARCHAR, date VARCHAR, format VARCHAR) ### OUTPUT SELECT region FROM table_name_91 WHERE date = "november 10, 2007" AND format = "cd"
{ "input": "CREATE TABLE table_name_91 (region VARCHAR, date VARCHAR, format VARCHAR)", "instruction": "What's the region for an item on November 10, 2007 that's a cd?", "output": "SELECT region FROM table_name_91 WHERE date = \"november 10, 2007\" AND format = \"cd\"" }
### INSTRUCTION Find the name of dorms which have TV Lounge but no Study Room as amenity. ### INPUT CREATE TABLE dorm (dorm_name VARCHAR, dormid VARCHAR); CREATE TABLE has_amenity (dormid VARCHAR, amenid VARCHAR); CREATE TABLE dorm_amenity (amenid VARCHAR, amenity_name VARCHAR) ### OUTPUT SELECT T1.dorm_name FROM dorm AS T1 JOIN has_amenity AS T2 ON T1.dormid = T2.dormid JOIN dorm_amenity AS T3 ON T2.amenid = T3.amenid WHERE T3.amenity_name = 'TV Lounge' EXCEPT SELECT T1.dorm_name FROM dorm AS T1 JOIN has_amenity AS T2 ON T1.dormid = T2.dormid JOIN dorm_amenity AS T3 ON T2.amenid = T3.amenid WHERE T3.amenity_name = 'Study Room'
{ "input": "CREATE TABLE dorm (dorm_name VARCHAR, dormid VARCHAR); CREATE TABLE has_amenity (dormid VARCHAR, amenid VARCHAR); CREATE TABLE dorm_amenity (amenid VARCHAR, amenity_name VARCHAR)", "instruction": "Find the name of dorms which have TV Lounge but no Study Room as amenity.", "output": "SELECT T1.dorm_name FROM dorm AS T1 JOIN has_amenity AS T2 ON T1.dormid = T2.dormid JOIN dorm_amenity AS T3 ON T2.amenid = T3.amenid WHERE T3.amenity_name = 'TV Lounge' EXCEPT SELECT T1.dorm_name FROM dorm AS T1 JOIN has_amenity AS T2 ON T1.dormid = T2.dormid JOIN dorm_amenity AS T3 ON T2.amenid = T3.amenid WHERE T3.amenity_name = 'Study Room'" }
### INSTRUCTION Which country has a rollercoaster that opened in 2002, is a spinning coaster, and is located in Disney's Animal Kingdom? ### INPUT CREATE TABLE table_name_76 (country VARCHAR, park VARCHAR, opened VARCHAR, model VARCHAR) ### OUTPUT SELECT country FROM table_name_76 WHERE opened = 2002 AND model = "spinning coaster" AND park = "disney's animal kingdom"
{ "input": "CREATE TABLE table_name_76 (country VARCHAR, park VARCHAR, opened VARCHAR, model VARCHAR)", "instruction": "Which country has a rollercoaster that opened in 2002, is a spinning coaster, and is located in Disney's Animal Kingdom?", "output": "SELECT country FROM table_name_76 WHERE opened = 2002 AND model = \"spinning coaster\" AND park = \"disney's animal kingdom\"" }
### INSTRUCTION What are Doug Davis' maximum pitching stats? ### INPUT CREATE TABLE table_19839391_3 (stats INTEGER, pitcher VARCHAR) ### OUTPUT SELECT MAX(stats) FROM table_19839391_3 WHERE pitcher = "Doug Davis"
{ "input": "CREATE TABLE table_19839391_3 (stats INTEGER, pitcher VARCHAR)", "instruction": "What are Doug Davis' maximum pitching stats?", "output": "SELECT MAX(stats) FROM table_19839391_3 WHERE pitcher = \"Doug Davis\"" }
### INSTRUCTION Which Staying councillors have a New council of 7, and a Previous council larger than 8? ### INPUT CREATE TABLE table_name_22 (staying_councillors INTEGER, new_council VARCHAR, previous_council VARCHAR) ### OUTPUT SELECT AVG(staying_councillors) FROM table_name_22 WHERE new_council = 7 AND previous_council > 8
{ "input": "CREATE TABLE table_name_22 (staying_councillors INTEGER, new_council VARCHAR, previous_council VARCHAR)", "instruction": "Which Staying councillors have a New council of 7, and a Previous council larger than 8?", "output": "SELECT AVG(staying_councillors) FROM table_name_22 WHERE new_council = 7 AND previous_council > 8" }
### INSTRUCTION Which Supplier have a Basic shape of flat, a Wrist pad of no, and Keys (x modes) of 25+? ### INPUT CREATE TABLE table_name_16 (supplier VARCHAR, keys__x_modes_ VARCHAR, basic_shape VARCHAR, wrist_pad VARCHAR) ### OUTPUT SELECT supplier FROM table_name_16 WHERE basic_shape = "flat" AND wrist_pad = "no" AND keys__x_modes_ = "25+"
{ "input": "CREATE TABLE table_name_16 (supplier VARCHAR, keys__x_modes_ VARCHAR, basic_shape VARCHAR, wrist_pad VARCHAR)", "instruction": "Which Supplier have a Basic shape of flat, a Wrist pad of no, and Keys (x modes) of 25+?", "output": "SELECT supplier FROM table_name_16 WHERE basic_shape = \"flat\" AND wrist_pad = \"no\" AND keys__x_modes_ = \"25+\"" }
### INSTRUCTION Where is every location with specialization of textile engineering? ### INPUT CREATE TABLE table_2112260_1 (location VARCHAR, specialization VARCHAR) ### OUTPUT SELECT location FROM table_2112260_1 WHERE specialization = "Textile engineering"
{ "input": "CREATE TABLE table_2112260_1 (location VARCHAR, specialization VARCHAR)", "instruction": "Where is every location with specialization of textile engineering?", "output": "SELECT location FROM table_2112260_1 WHERE specialization = \"Textile engineering\"" }
### INSTRUCTION Who was Mountains Classification in the race with Nick Frey as Youth Classification and Tom Zirbel as Points Classification? ### INPUT CREATE TABLE table_23157997_13 (mountains_classification VARCHAR, youth_classification VARCHAR, points_classification VARCHAR) ### OUTPUT SELECT mountains_classification FROM table_23157997_13 WHERE youth_classification = "Nick Frey" AND points_classification = "Tom Zirbel"
{ "input": "CREATE TABLE table_23157997_13 (mountains_classification VARCHAR, youth_classification VARCHAR, points_classification VARCHAR)", "instruction": "Who was Mountains Classification in the race with Nick Frey as Youth Classification and Tom Zirbel as Points Classification?", "output": "SELECT mountains_classification FROM table_23157997_13 WHERE youth_classification = \"Nick Frey\" AND points_classification = \"Tom Zirbel\"" }
### INSTRUCTION What are the locations with a panthers mascot? ### INPUT CREATE TABLE table_13456202_1 (location VARCHAR, mascot VARCHAR) ### OUTPUT SELECT location FROM table_13456202_1 WHERE mascot = "Panthers"
{ "input": "CREATE TABLE table_13456202_1 (location VARCHAR, mascot VARCHAR)", "instruction": "What are the locations with a panthers mascot?", "output": "SELECT location FROM table_13456202_1 WHERE mascot = \"Panthers\"" }
### INSTRUCTION For the Enernoc Australia Pty Ltd, what's the country with an unknown date? ### INPUT CREATE TABLE table_name_15 (country VARCHAR, date VARCHAR, company VARCHAR) ### OUTPUT SELECT country FROM table_name_15 WHERE date = "unknown" AND company = "enernoc australia pty ltd"
{ "input": "CREATE TABLE table_name_15 (country VARCHAR, date VARCHAR, company VARCHAR)", "instruction": "For the Enernoc Australia Pty Ltd, what's the country with an unknown date?", "output": "SELECT country FROM table_name_15 WHERE date = \"unknown\" AND company = \"enernoc australia pty ltd\"" }
### INSTRUCTION What is the score of the tournament with a carpet surface and tim henman as the partnering? ### INPUT CREATE TABLE table_name_88 (score VARCHAR, surface VARCHAR, partnering VARCHAR) ### OUTPUT SELECT score FROM table_name_88 WHERE surface = "carpet" AND partnering = "tim henman"
{ "input": "CREATE TABLE table_name_88 (score VARCHAR, surface VARCHAR, partnering VARCHAR)", "instruction": "What is the score of the tournament with a carpet surface and tim henman as the partnering?", "output": "SELECT score FROM table_name_88 WHERE surface = \"carpet\" AND partnering = \"tim henman\"" }
### INSTRUCTION What is the record of the game with Mason as the decision and Nashville as the home team? ### INPUT CREATE TABLE table_name_45 (record VARCHAR, decision VARCHAR, home VARCHAR) ### OUTPUT SELECT record FROM table_name_45 WHERE decision = "mason" AND home = "nashville"
{ "input": "CREATE TABLE table_name_45 (record VARCHAR, decision VARCHAR, home VARCHAR)", "instruction": "What is the record of the game with Mason as the decision and Nashville as the home team?", "output": "SELECT record FROM table_name_45 WHERE decision = \"mason\" AND home = \"nashville\"" }
### INSTRUCTION what being the maximum total passengers 2008 with change 2008/09 being 6.5% ### INPUT CREATE TABLE table_13836704_4 (total_passengers_2008 INTEGER, change_2008_09 VARCHAR) ### OUTPUT SELECT MAX(total_passengers_2008) FROM table_13836704_4 WHERE change_2008_09 = "6.5%"
{ "input": "CREATE TABLE table_13836704_4 (total_passengers_2008 INTEGER, change_2008_09 VARCHAR)", "instruction": "what being the maximum total passengers 2008 with change 2008/09 being 6.5%", "output": "SELECT MAX(total_passengers_2008) FROM table_13836704_4 WHERE change_2008_09 = \"6.5%\"" }
### INSTRUCTION Which chassis did Aguri Suzuki drive with an entrant of Larrousse F1? ### INPUT CREATE TABLE table_name_41 (chassis VARCHAR, entrant VARCHAR, driver VARCHAR) ### OUTPUT SELECT chassis FROM table_name_41 WHERE entrant = "larrousse f1" AND driver = "aguri suzuki"
{ "input": "CREATE TABLE table_name_41 (chassis VARCHAR, entrant VARCHAR, driver VARCHAR)", "instruction": "Which chassis did Aguri Suzuki drive with an entrant of Larrousse F1?", "output": "SELECT chassis FROM table_name_41 WHERE entrant = \"larrousse f1\" AND driver = \"aguri suzuki\"" }
### INSTRUCTION Can you tell me the Wins that has the Starts larger than 1, and the Top 5 of 3? ### INPUT CREATE TABLE table_name_19 (wins VARCHAR, starts VARCHAR, top_5 VARCHAR) ### OUTPUT SELECT wins FROM table_name_19 WHERE starts > 1 AND top_5 = 3
{ "input": "CREATE TABLE table_name_19 (wins VARCHAR, starts VARCHAR, top_5 VARCHAR)", "instruction": "Can you tell me the Wins that has the Starts larger than 1, and the Top 5 of 3?", "output": "SELECT wins FROM table_name_19 WHERE starts > 1 AND top_5 = 3" }
### INSTRUCTION What was the final score of the player from Inglewood, California? ### INPUT CREATE TABLE table_name_14 (score VARCHAR, city VARCHAR) ### OUTPUT SELECT score FROM table_name_14 WHERE city = "inglewood, california"
{ "input": "CREATE TABLE table_name_14 (score VARCHAR, city VARCHAR)", "instruction": "What was the final score of the player from Inglewood, California?", "output": "SELECT score FROM table_name_14 WHERE city = \"inglewood, california\"" }
### INSTRUCTION Who is the winner of the Florence to Genoa course? ### INPUT CREATE TABLE table_name_95 (winner VARCHAR, course VARCHAR) ### OUTPUT SELECT winner FROM table_name_95 WHERE course = "florence to genoa"
{ "input": "CREATE TABLE table_name_95 (winner VARCHAR, course VARCHAR)", "instruction": "Who is the winner of the Florence to Genoa course?", "output": "SELECT winner FROM table_name_95 WHERE course = \"florence to genoa\"" }
### INSTRUCTION Show the names of journalists and the names of the events they reported in ascending order ### INPUT CREATE TABLE journalist (Name VARCHAR, journalist_ID VARCHAR); CREATE TABLE news_report (Event_ID VARCHAR, journalist_ID VARCHAR); CREATE TABLE event (Name VARCHAR, Event_ID VARCHAR, Event_Attendance VARCHAR) ### OUTPUT SELECT T3.Name, T2.Name FROM news_report AS T1 JOIN event AS T2 ON T1.Event_ID = T2.Event_ID JOIN journalist AS T3 ON T1.journalist_ID = T3.journalist_ID ORDER BY T2.Event_Attendance
{ "input": "CREATE TABLE journalist (Name VARCHAR, journalist_ID VARCHAR); CREATE TABLE news_report (Event_ID VARCHAR, journalist_ID VARCHAR); CREATE TABLE event (Name VARCHAR, Event_ID VARCHAR, Event_Attendance VARCHAR)", "instruction": "Show the names of journalists and the names of the events they reported in ascending order", "output": "SELECT T3.Name, T2.Name FROM news_report AS T1 JOIN event AS T2 ON T1.Event_ID = T2.Event_ID JOIN journalist AS T3 ON T1.journalist_ID = T3.journalist_ID ORDER BY T2.Event_Attendance" }
### INSTRUCTION Which stage has a mountains classification of Mariano Piccoli, a points classification of Mario Cipollini and was won by Laudelino Cubino? ### INPUT CREATE TABLE table_name_93 (stage VARCHAR, winner VARCHAR, mountains_classification VARCHAR, points_classification VARCHAR) ### OUTPUT SELECT stage FROM table_name_93 WHERE mountains_classification = "mariano piccoli" AND points_classification = "mario cipollini" AND winner = "laudelino cubino"
{ "input": "CREATE TABLE table_name_93 (stage VARCHAR, winner VARCHAR, mountains_classification VARCHAR, points_classification VARCHAR)", "instruction": "Which stage has a mountains classification of Mariano Piccoli, a points classification of Mario Cipollini and was won by Laudelino Cubino?", "output": "SELECT stage FROM table_name_93 WHERE mountains_classification = \"mariano piccoli\" AND points_classification = \"mario cipollini\" AND winner = \"laudelino cubino\"" }
### INSTRUCTION Which Chart peak has a Time of 3:11? ### INPUT CREATE TABLE table_name_30 (chart_peak VARCHAR, time VARCHAR) ### OUTPUT SELECT chart_peak FROM table_name_30 WHERE time = "3:11"
{ "input": "CREATE TABLE table_name_30 (chart_peak VARCHAR, time VARCHAR)", "instruction": "Which Chart peak has a Time of 3:11?", "output": "SELECT chart_peak FROM table_name_30 WHERE time = \"3:11\"" }
### INSTRUCTION What is the total for National University of Ireland with an industrial and commercial panel less than 1, and the cultural and educational panel bigger than 0? ### INPUT CREATE TABLE table_name_17 (national_university_of_ireland VARCHAR, industrial_and_commercial_panel VARCHAR, cultural_and_educational_panel VARCHAR) ### OUTPUT SELECT COUNT(national_university_of_ireland) FROM table_name_17 WHERE industrial_and_commercial_panel < 1 AND cultural_and_educational_panel > 0
{ "input": "CREATE TABLE table_name_17 (national_university_of_ireland VARCHAR, industrial_and_commercial_panel VARCHAR, cultural_and_educational_panel VARCHAR)", "instruction": "What is the total for National University of Ireland with an industrial and commercial panel less than 1, and the cultural and educational panel bigger than 0?", "output": "SELECT COUNT(national_university_of_ireland) FROM table_name_17 WHERE industrial_and_commercial_panel < 1 AND cultural_and_educational_panel > 0" }
### INSTRUCTION When the elevator was Innocent IV what was the nationality? ### INPUT CREATE TABLE table_name_98 (nationality VARCHAR, elevator VARCHAR) ### OUTPUT SELECT nationality FROM table_name_98 WHERE elevator = "innocent iv"
{ "input": "CREATE TABLE table_name_98 (nationality VARCHAR, elevator VARCHAR)", "instruction": "When the elevator was Innocent IV what was the nationality?", "output": "SELECT nationality FROM table_name_98 WHERE elevator = \"innocent iv\"" }
### INSTRUCTION What are the notes for svishtov , bulgaria? ### INPUT CREATE TABLE table_242785_1 (notes VARCHAR, main_legionary_base VARCHAR) ### OUTPUT SELECT notes FROM table_242785_1 WHERE main_legionary_base = "Svishtov , Bulgaria"
{ "input": "CREATE TABLE table_242785_1 (notes VARCHAR, main_legionary_base VARCHAR)", "instruction": "What are the notes for svishtov , bulgaria?", "output": "SELECT notes FROM table_242785_1 WHERE main_legionary_base = \"Svishtov , Bulgaria\"" }
### INSTRUCTION Which career win-loss record has a 1r in 2002, a 2r in 2000 and a 2r in 2001? ### INPUT CREATE TABLE table_name_75 (career_win_loss VARCHAR) ### OUTPUT SELECT career_win_loss FROM table_name_75 WHERE 2002 = "1r" AND 2000 = "2r" AND 2001 = "2r"
{ "input": "CREATE TABLE table_name_75 (career_win_loss VARCHAR)", "instruction": "Which career win-loss record has a 1r in 2002, a 2r in 2000 and a 2r in 2001?", "output": "SELECT career_win_loss FROM table_name_75 WHERE 2002 = \"1r\" AND 2000 = \"2r\" AND 2001 = \"2r\"" }
### INSTRUCTION What team did Russ Wiechnik, on the centre position, come from? ### INPUT CREATE TABLE table_1965650_11 (college_junior_club_team VARCHAR, position VARCHAR, player VARCHAR) ### OUTPUT SELECT college_junior_club_team FROM table_1965650_11 WHERE position = "Centre" AND player = "Russ Wiechnik"
{ "input": "CREATE TABLE table_1965650_11 (college_junior_club_team VARCHAR, position VARCHAR, player VARCHAR)", "instruction": "What team did Russ Wiechnik, on the centre position, come from?", "output": "SELECT college_junior_club_team FROM table_1965650_11 WHERE position = \"Centre\" AND player = \"Russ Wiechnik\"" }
### INSTRUCTION display the department ID, full name (first and last name), salary for those employees who is highest salary in every department. ### INPUT CREATE TABLE employees (first_name VARCHAR, last_name VARCHAR, salary INTEGER, department_id VARCHAR) ### OUTPUT SELECT first_name, last_name, salary, department_id, MAX(salary) FROM employees GROUP BY department_id
{ "input": "CREATE TABLE employees (first_name VARCHAR, last_name VARCHAR, salary INTEGER, department_id VARCHAR)", "instruction": "display the department ID, full name (first and last name), salary for those employees who is highest salary in every department.", "output": "SELECT first_name, last_name, salary, department_id, MAX(salary) FROM employees GROUP BY department_id" }
### INSTRUCTION What was the highest rank by average of a couple who had an average of 25.3 and had more than 10 dances? ### INPUT CREATE TABLE table_name_27 (rank_by_average INTEGER, average VARCHAR, number_of_dances VARCHAR) ### OUTPUT SELECT MAX(rank_by_average) FROM table_name_27 WHERE average = 25.3 AND number_of_dances > 10
{ "input": "CREATE TABLE table_name_27 (rank_by_average INTEGER, average VARCHAR, number_of_dances VARCHAR)", "instruction": "What was the highest rank by average of a couple who had an average of 25.3 and had more than 10 dances?", "output": "SELECT MAX(rank_by_average) FROM table_name_27 WHERE average = 25.3 AND number_of_dances > 10" }
### INSTRUCTION What is week 7 when week 3 is 35.90? ### INPUT CREATE TABLE table_name_62 (week_7 VARCHAR, week_3 VARCHAR) ### OUTPUT SELECT week_7 FROM table_name_62 WHERE week_3 = "35.90"
{ "input": "CREATE TABLE table_name_62 (week_7 VARCHAR, week_3 VARCHAR)", "instruction": "What is week 7 when week 3 is 35.90?", "output": "SELECT week_7 FROM table_name_62 WHERE week_3 = \"35.90\"" }
### INSTRUCTION What is Date, when Opposing Teams is "South Africa", and when Venus is "Vodacom Park , Bloemfontein"? ### INPUT CREATE TABLE table_name_22 (date VARCHAR, opposing_teams VARCHAR, venue VARCHAR) ### OUTPUT SELECT date FROM table_name_22 WHERE opposing_teams = "south africa" AND venue = "vodacom park , bloemfontein"
{ "input": "CREATE TABLE table_name_22 (date VARCHAR, opposing_teams VARCHAR, venue VARCHAR)", "instruction": "What is Date, when Opposing Teams is \"South Africa\", and when Venus is \"Vodacom Park , Bloemfontein\"?", "output": "SELECT date FROM table_name_22 WHERE opposing_teams = \"south africa\" AND venue = \"vodacom park , bloemfontein\"" }
### INSTRUCTION Who is The Spouse of the Duchess that has a Became Duchess on 31 october 1733 husband's accession? ### INPUT CREATE TABLE table_name_31 (spouse VARCHAR, became_duchess VARCHAR) ### OUTPUT SELECT spouse FROM table_name_31 WHERE became_duchess = "31 october 1733 husband's accession"
{ "input": "CREATE TABLE table_name_31 (spouse VARCHAR, became_duchess VARCHAR)", "instruction": "Who is The Spouse of the Duchess that has a Became Duchess on 31 october 1733 husband's accession?", "output": "SELECT spouse FROM table_name_31 WHERE became_duchess = \"31 october 1733 husband's accession\"" }
### INSTRUCTION What venue held the 1966 fifa world cup qualification on may 7, 1965? ### INPUT CREATE TABLE table_name_95 (venue VARCHAR, competition VARCHAR, date VARCHAR) ### OUTPUT SELECT venue FROM table_name_95 WHERE competition = "1966 fifa world cup qualification" AND date = "may 7, 1965"
{ "input": "CREATE TABLE table_name_95 (venue VARCHAR, competition VARCHAR, date VARCHAR)", "instruction": "What venue held the 1966 fifa world cup qualification on may 7, 1965?", "output": "SELECT venue FROM table_name_95 WHERE competition = \"1966 fifa world cup qualification\" AND date = \"may 7, 1965\"" }
### INSTRUCTION Which school did the player then go to Auburn? ### INPUT CREATE TABLE table_11677691_7 (school VARCHAR, college VARCHAR) ### OUTPUT SELECT school FROM table_11677691_7 WHERE college = "Auburn"
{ "input": "CREATE TABLE table_11677691_7 (school VARCHAR, college VARCHAR)", "instruction": "Which school did the player then go to Auburn?", "output": "SELECT school FROM table_11677691_7 WHERE college = \"Auburn\"" }
### INSTRUCTION What is the Club, when the value for Lost is 9, and when the value for Tries is 55? ### INPUT CREATE TABLE table_name_8 (club VARCHAR, lost VARCHAR, tries_for VARCHAR) ### OUTPUT SELECT club FROM table_name_8 WHERE lost = "9" AND tries_for = "55"
{ "input": "CREATE TABLE table_name_8 (club VARCHAR, lost VARCHAR, tries_for VARCHAR)", "instruction": "What is the Club, when the value for Lost is 9, and when the value for Tries is 55?", "output": "SELECT club FROM table_name_8 WHERE lost = \"9\" AND tries_for = \"55\"" }
### INSTRUCTION What was the production code of the episode written by Anthony Sparks? ### INPUT CREATE TABLE table_25851971_1 (production_code VARCHAR, written_by VARCHAR) ### OUTPUT SELECT production_code FROM table_25851971_1 WHERE written_by = "Anthony Sparks"
{ "input": "CREATE TABLE table_25851971_1 (production_code VARCHAR, written_by VARCHAR)", "instruction": "What was the production code of the episode written by Anthony Sparks?", "output": "SELECT production_code FROM table_25851971_1 WHERE written_by = \"Anthony Sparks\"" }
### INSTRUCTION what is the location attendance when the score is w 86–77 (ot)? ### INPUT CREATE TABLE table_name_42 (location_attendance VARCHAR, score VARCHAR) ### OUTPUT SELECT location_attendance FROM table_name_42 WHERE score = "w 86–77 (ot)"
{ "input": "CREATE TABLE table_name_42 (location_attendance VARCHAR, score VARCHAR)", "instruction": "what is the location attendance when the score is w 86–77 (ot)?", "output": "SELECT location_attendance FROM table_name_42 WHERE score = \"w 86–77 (ot)\"" }
### INSTRUCTION How many years was Best Musical Revival nominated? ### INPUT CREATE TABLE table_name_60 (year VARCHAR, nominee VARCHAR) ### OUTPUT SELECT COUNT(year) FROM table_name_60 WHERE nominee = "best musical revival"
{ "input": "CREATE TABLE table_name_60 (year VARCHAR, nominee VARCHAR)", "instruction": "How many years was Best Musical Revival nominated?", "output": "SELECT COUNT(year) FROM table_name_60 WHERE nominee = \"best musical revival\"" }
### INSTRUCTION What is the local mission that has none as a local location, high commissioner as a local position, fiji as a resident county, and a mission of tonga? ### INPUT CREATE TABLE table_name_41 (Local VARCHAR, mission VARCHAR, resident_country VARCHAR, local_location VARCHAR, local_position VARCHAR) ### OUTPUT SELECT Local AS mission FROM table_name_41 WHERE local_location = "none" AND local_position = "high commissioner" AND resident_country = "fiji" AND mission = "tonga"
{ "input": "CREATE TABLE table_name_41 (Local VARCHAR, mission VARCHAR, resident_country VARCHAR, local_location VARCHAR, local_position VARCHAR)", "instruction": "What is the local mission that has none as a local location, high commissioner as a local position, fiji as a resident county, and a mission of tonga?", "output": "SELECT Local AS mission FROM table_name_41 WHERE local_location = \"none\" AND local_position = \"high commissioner\" AND resident_country = \"fiji\" AND mission = \"tonga\"" }
### INSTRUCTION How long is the bridge in Villeneuve-sur-Lot? ### INPUT CREATE TABLE table_name_40 (longest_span_in_s_metre___feet__ VARCHAR, location VARCHAR) ### OUTPUT SELECT longest_span_in_s_metre___feet__ FROM table_name_40 WHERE location = "villeneuve-sur-lot"
{ "input": "CREATE TABLE table_name_40 (longest_span_in_s_metre___feet__ VARCHAR, location VARCHAR)", "instruction": "How long is the bridge in Villeneuve-sur-Lot?", "output": "SELECT longest_span_in_s_metre___feet__ FROM table_name_40 WHERE location = \"villeneuve-sur-lot\"" }
### INSTRUCTION What was the enrollment (2005) for baccalaureate colleges , for Granite State College? ### INPUT CREATE TABLE table_2076490_1 (enrollment__2005_ VARCHAR, type VARCHAR, school VARCHAR) ### OUTPUT SELECT enrollment__2005_ FROM table_2076490_1 WHERE type = "Baccalaureate college" AND school = "Granite State College"
{ "input": "CREATE TABLE table_2076490_1 (enrollment__2005_ VARCHAR, type VARCHAR, school VARCHAR)", "instruction": "What was the enrollment (2005) for baccalaureate colleges , for Granite State College?", "output": "SELECT enrollment__2005_ FROM table_2076490_1 WHERE type = \"Baccalaureate college\" AND school = \"Granite State College\"" }
### INSTRUCTION How many instruments does the song "Badlands" use? ### INPUT CREATE TABLE instruments (songid VARCHAR); CREATE TABLE songs (songid VARCHAR) ### OUTPUT SELECT COUNT(DISTINCT instrument) FROM instruments AS T1 JOIN songs AS T2 ON T1.songid = T2.songid WHERE title = "Badlands"
{ "input": "CREATE TABLE instruments (songid VARCHAR); CREATE TABLE songs (songid VARCHAR)", "instruction": "How many instruments does the song \"Badlands\" use?", "output": "SELECT COUNT(DISTINCT instrument) FROM instruments AS T1 JOIN songs AS T2 ON T1.songid = T2.songid WHERE title = \"Badlands\"" }
### INSTRUCTION What is the height of the person whose position is Libero? ### INPUT CREATE TABLE table_name_15 (height INTEGER, position VARCHAR) ### OUTPUT SELECT MAX(height) FROM table_name_15 WHERE position = "libero"
{ "input": "CREATE TABLE table_name_15 (height INTEGER, position VARCHAR)", "instruction": "What is the height of the person whose position is Libero?", "output": "SELECT MAX(height) FROM table_name_15 WHERE position = \"libero\"" }
### INSTRUCTION Name the international tourist arrivals for arrivals 2011 for 8.1 million ### INPUT CREATE TABLE table_14752049_3 (international_tourist_arrivals__2010_ VARCHAR, international_tourist_arrivals__2011_ VARCHAR) ### OUTPUT SELECT international_tourist_arrivals__2010_ FROM table_14752049_3 WHERE international_tourist_arrivals__2011_ = "8.1 million"
{ "input": "CREATE TABLE table_14752049_3 (international_tourist_arrivals__2010_ VARCHAR, international_tourist_arrivals__2011_ VARCHAR)", "instruction": "Name the international tourist arrivals for arrivals 2011 for 8.1 million", "output": "SELECT international_tourist_arrivals__2010_ FROM table_14752049_3 WHERE international_tourist_arrivals__2011_ = \"8.1 million\"" }
### INSTRUCTION What is the lowest Attendance, when Home Team is "Welling United"? ### INPUT CREATE TABLE table_name_26 (attendance INTEGER, home_team VARCHAR) ### OUTPUT SELECT MIN(attendance) FROM table_name_26 WHERE home_team = "welling united"
{ "input": "CREATE TABLE table_name_26 (attendance INTEGER, home_team VARCHAR)", "instruction": "What is the lowest Attendance, when Home Team is \"Welling United\"?", "output": "SELECT MIN(attendance) FROM table_name_26 WHERE home_team = \"welling united\"" }
### INSTRUCTION What is the id of the project with least number of documents? ### INPUT CREATE TABLE Documents (project_id VARCHAR) ### OUTPUT SELECT project_id FROM Documents GROUP BY project_id ORDER BY COUNT(*) LIMIT 1
{ "input": "CREATE TABLE Documents (project_id VARCHAR)", "instruction": "What is the id of the project with least number of documents?", "output": "SELECT project_id FROM Documents GROUP BY project_id ORDER BY COUNT(*) LIMIT 1" }
### INSTRUCTION Name the number of tenants for russia at the saransk stadium ### INPUT CREATE TABLE table_28281704_1 (tenant VARCHAR, country VARCHAR, stadium VARCHAR) ### OUTPUT SELECT COUNT(tenant) FROM table_28281704_1 WHERE country = "Russia" AND stadium = "Saransk stadium"
{ "input": "CREATE TABLE table_28281704_1 (tenant VARCHAR, country VARCHAR, stadium VARCHAR)", "instruction": "Name the number of tenants for russia at the saransk stadium", "output": "SELECT COUNT(tenant) FROM table_28281704_1 WHERE country = \"Russia\" AND stadium = \"Saransk stadium\"" }
### INSTRUCTION What is the Week number on November 30, 1958 with more than 33,240 in Attendance? ### INPUT CREATE TABLE table_name_64 (week VARCHAR, date VARCHAR, attendance VARCHAR) ### OUTPUT SELECT COUNT(week) FROM table_name_64 WHERE date = "november 30, 1958" AND attendance > 33 OFFSET 240
{ "input": "CREATE TABLE table_name_64 (week VARCHAR, date VARCHAR, attendance VARCHAR)", "instruction": "What is the Week number on November 30, 1958 with more than 33,240 in Attendance?", "output": "SELECT COUNT(week) FROM table_name_64 WHERE date = \"november 30, 1958\" AND attendance > 33 OFFSET 240" }
### INSTRUCTION How many silver medals were awarded to the Nation with less than 2 gold, more than 6 bronze and a rank higher than 5? ### INPUT CREATE TABLE table_name_33 (silver INTEGER, gold VARCHAR, rank VARCHAR, bronze VARCHAR) ### OUTPUT SELECT SUM(silver) FROM table_name_33 WHERE rank > 5 AND bronze > 6 AND gold < 2
{ "input": "CREATE TABLE table_name_33 (silver INTEGER, gold VARCHAR, rank VARCHAR, bronze VARCHAR)", "instruction": "How many silver medals were awarded to the Nation with less than 2 gold, more than 6 bronze and a rank higher than 5?", "output": "SELECT SUM(silver) FROM table_name_33 WHERE rank > 5 AND bronze > 6 AND gold < 2" }
### INSTRUCTION What was the minimal amount ($) of the 1st prize in the tournaments in New Mexico? ### INPUT CREATE TABLE table_11622562_1 (location VARCHAR) ### OUTPUT SELECT MIN(*) AS $__ FROM table_11622562_1 WHERE location = "New Mexico"
{ "input": "CREATE TABLE table_11622562_1 (location VARCHAR)", "instruction": "What was the minimal amount ($) of the 1st prize in the tournaments in New Mexico?", "output": "SELECT MIN(*) AS $__ FROM table_11622562_1 WHERE location = \"New Mexico\"" }
### INSTRUCTION Who was the general classification leader when the young rider classification leader was Salvatore Commesso and the winner was Erik Dekker? ### INPUT CREATE TABLE table_2267345_2 (general_classification VARCHAR, young_rider_classification VARCHAR, winner VARCHAR) ### OUTPUT SELECT general_classification FROM table_2267345_2 WHERE young_rider_classification = "Salvatore Commesso" AND winner = "Erik Dekker"
{ "input": "CREATE TABLE table_2267345_2 (general_classification VARCHAR, young_rider_classification VARCHAR, winner VARCHAR)", "instruction": "Who was the general classification leader when the young rider classification leader was Salvatore Commesso and the winner was Erik Dekker?", "output": "SELECT general_classification FROM table_2267345_2 WHERE young_rider_classification = \"Salvatore Commesso\" AND winner = \"Erik Dekker\"" }
### INSTRUCTION Find the names of items whose rank is higher than 3 and whose average rating is above 5. ### INPUT CREATE TABLE item (title VARCHAR, i_id VARCHAR); CREATE TABLE review (i_id VARCHAR, rank INTEGER, rating INTEGER) ### OUTPUT SELECT T1.title FROM item AS T1 JOIN review AS T2 ON T1.i_id = T2.i_id WHERE T2.rank > 3 INTERSECT SELECT T1.title FROM item AS T1 JOIN review AS T2 ON T1.i_id = T2.i_id GROUP BY T2.i_id HAVING AVG(T2.rating) > 5
{ "input": "CREATE TABLE item (title VARCHAR, i_id VARCHAR); CREATE TABLE review (i_id VARCHAR, rank INTEGER, rating INTEGER)", "instruction": "Find the names of items whose rank is higher than 3 and whose average rating is above 5.", "output": "SELECT T1.title FROM item AS T1 JOIN review AS T2 ON T1.i_id = T2.i_id WHERE T2.rank > 3 INTERSECT SELECT T1.title FROM item AS T1 JOIN review AS T2 ON T1.i_id = T2.i_id GROUP BY T2.i_id HAVING AVG(T2.rating) > 5" }
### INSTRUCTION How many numbers were recorded under revenue when revenue per capita was $6,126? ### INPUT CREATE TABLE table_14700336_1 (revenue__millions_ VARCHAR, revenue_per_capita VARCHAR) ### OUTPUT SELECT COUNT(revenue__millions_) FROM table_14700336_1 WHERE revenue_per_capita = "$6,126"
{ "input": "CREATE TABLE table_14700336_1 (revenue__millions_ VARCHAR, revenue_per_capita VARCHAR)", "instruction": "How many numbers were recorded under revenue when revenue per capita was $6,126?", "output": "SELECT COUNT(revenue__millions_) FROM table_14700336_1 WHERE revenue_per_capita = \"$6,126\"" }
### INSTRUCTION Which Poll source has a Peg Luksik of 9%, and Dates administered of may 12, 2010? ### INPUT CREATE TABLE table_name_2 (poll_source VARCHAR, peg_luksik VARCHAR, dates_administered VARCHAR) ### OUTPUT SELECT poll_source FROM table_name_2 WHERE peg_luksik = "9%" AND dates_administered = "may 12, 2010"
{ "input": "CREATE TABLE table_name_2 (poll_source VARCHAR, peg_luksik VARCHAR, dates_administered VARCHAR)", "instruction": "Which Poll source has a Peg Luksik of 9%, and Dates administered of may 12, 2010?", "output": "SELECT poll_source FROM table_name_2 WHERE peg_luksik = \"9%\" AND dates_administered = \"may 12, 2010\"" }
### INSTRUCTION Show the name, location, open year for all tracks with a seating higher than the average. ### INPUT CREATE TABLE track (name VARCHAR, LOCATION VARCHAR, year_opened VARCHAR, seating INTEGER) ### OUTPUT SELECT name, LOCATION, year_opened FROM track WHERE seating > (SELECT AVG(seating) FROM track)
{ "input": "CREATE TABLE track (name VARCHAR, LOCATION VARCHAR, year_opened VARCHAR, seating INTEGER)", "instruction": "Show the name, location, open year for all tracks with a seating higher than the average.", "output": "SELECT name, LOCATION, year_opened FROM track WHERE seating > (SELECT AVG(seating) FROM track)" }
### INSTRUCTION Which Facility ID has a City of license of springfield, ma, and a ERP / Power W smaller than 230? ### INPUT CREATE TABLE table_name_15 (facility_id INTEGER, city_of_license VARCHAR, erp___power_w VARCHAR) ### OUTPUT SELECT MAX(facility_id) FROM table_name_15 WHERE city_of_license = "springfield, ma" AND erp___power_w < 230
{ "input": "CREATE TABLE table_name_15 (facility_id INTEGER, city_of_license VARCHAR, erp___power_w VARCHAR)", "instruction": "Which Facility ID has a City of license of springfield, ma, and a ERP / Power W smaller than 230?", "output": "SELECT MAX(facility_id) FROM table_name_15 WHERE city_of_license = \"springfield, ma\" AND erp___power_w < 230" }
### INSTRUCTION What is the name of the player with the High rebounds when there was a Score of l 108–114 (ot)? ### INPUT CREATE TABLE table_name_25 (high_rebounds VARCHAR, score VARCHAR) ### OUTPUT SELECT high_rebounds FROM table_name_25 WHERE score = "l 108–114 (ot)"
{ "input": "CREATE TABLE table_name_25 (high_rebounds VARCHAR, score VARCHAR)", "instruction": "What is the name of the player with the High rebounds when there was a Score of l 108–114 (ot)?", "output": "SELECT high_rebounds FROM table_name_25 WHERE score = \"l 108–114 (ot)\"" }
### INSTRUCTION Which text has traditional characters of 心如猨猴? ### INPUT CREATE TABLE table_name_47 (text VARCHAR, traditional_characters VARCHAR) ### OUTPUT SELECT text FROM table_name_47 WHERE traditional_characters = "心如猨猴"
{ "input": "CREATE TABLE table_name_47 (text VARCHAR, traditional_characters VARCHAR)", "instruction": "Which text has traditional characters of 心如猨猴?", "output": "SELECT text FROM table_name_47 WHERE traditional_characters = \"心如猨猴\"" }
### INSTRUCTION What is the lowest number of goals joe keenan, who has more than 1 assists, had in 2007/08? ### INPUT CREATE TABLE table_name_84 (goals INTEGER, assists VARCHAR, years VARCHAR, name VARCHAR) ### OUTPUT SELECT MIN(goals) FROM table_name_84 WHERE years = "2007/08" AND name = "joe keenan" AND assists > 1
{ "input": "CREATE TABLE table_name_84 (goals INTEGER, assists VARCHAR, years VARCHAR, name VARCHAR)", "instruction": "What is the lowest number of goals joe keenan, who has more than 1 assists, had in 2007/08?", "output": "SELECT MIN(goals) FROM table_name_84 WHERE years = \"2007/08\" AND name = \"joe keenan\" AND assists > 1" }
### INSTRUCTION Which Blackpool has a Preston North End smaller than 46, and a Competition of other, and a Draw larger than 1? ### INPUT CREATE TABLE table_name_94 (blackpool INTEGER, draw VARCHAR, preston_north_end VARCHAR, competition VARCHAR) ### OUTPUT SELECT SUM(blackpool) FROM table_name_94 WHERE preston_north_end < 46 AND competition = "other" AND draw > 1
{ "input": "CREATE TABLE table_name_94 (blackpool INTEGER, draw VARCHAR, preston_north_end VARCHAR, competition VARCHAR)", "instruction": "Which Blackpool has a Preston North End smaller than 46, and a Competition of other, and a Draw larger than 1?", "output": "SELECT SUM(blackpool) FROM table_name_94 WHERE preston_north_end < 46 AND competition = \"other\" AND draw > 1" }
### INSTRUCTION What source has a race winner of ben adriaenssen / ben van den bogaart, and the gp winner of ben adriaenssen / ben van den bogaart, for the date of 1 april? ### INPUT CREATE TABLE table_name_8 (source VARCHAR, date VARCHAR, race_winners VARCHAR, gp_winner VARCHAR) ### OUTPUT SELECT source FROM table_name_8 WHERE race_winners = "ben adriaenssen / ben van den bogaart" AND gp_winner = "ben adriaenssen / ben van den bogaart" AND date = "1 april"
{ "input": "CREATE TABLE table_name_8 (source VARCHAR, date VARCHAR, race_winners VARCHAR, gp_winner VARCHAR)", "instruction": "What source has a race winner of ben adriaenssen / ben van den bogaart, and the gp winner of ben adriaenssen / ben van den bogaart, for the date of 1 april?", "output": "SELECT source FROM table_name_8 WHERE race_winners = \"ben adriaenssen / ben van den bogaart\" AND gp_winner = \"ben adriaenssen / ben van den bogaart\" AND date = \"1 april\"" }
### INSTRUCTION tell me the total number of decile with a roll showing 251. ### INPUT CREATE TABLE table_name_90 (decile VARCHAR, roll VARCHAR) ### OUTPUT SELECT COUNT(decile) FROM table_name_90 WHERE roll = 251
{ "input": "CREATE TABLE table_name_90 (decile VARCHAR, roll VARCHAR)", "instruction": "tell me the total number of decile with a roll showing 251.", "output": "SELECT COUNT(decile) FROM table_name_90 WHERE roll = 251" }
### INSTRUCTION What was the Stage when Pascal Richard had the Mountains classification and Vladimir Poulnikov won? ### INPUT CREATE TABLE table_name_71 (stage VARCHAR, mountains_classification VARCHAR, winner VARCHAR) ### OUTPUT SELECT stage FROM table_name_71 WHERE mountains_classification = "pascal richard" AND winner = "vladimir poulnikov"
{ "input": "CREATE TABLE table_name_71 (stage VARCHAR, mountains_classification VARCHAR, winner VARCHAR)", "instruction": "What was the Stage when Pascal Richard had the Mountains classification and Vladimir Poulnikov won?", "output": "SELECT stage FROM table_name_71 WHERE mountains_classification = \"pascal richard\" AND winner = \"vladimir poulnikov\"" }
### INSTRUCTION Who was the opponent in the Women's Cup 0 0 where Brancão Couto 0 is the scorer? ### INPUT CREATE TABLE table_27654988_1 (opponent VARCHAR, competition VARCHAR, scorers VARCHAR) ### OUTPUT SELECT opponent FROM table_27654988_1 WHERE competition = "Women's Cup 0 0" AND scorers = "Brancão Couto 0"
{ "input": "CREATE TABLE table_27654988_1 (opponent VARCHAR, competition VARCHAR, scorers VARCHAR)", "instruction": "Who was the opponent in the Women's Cup 0 0 where Brancão Couto 0 is the scorer?", "output": "SELECT opponent FROM table_27654988_1 WHERE competition = \"Women's Cup 0 0\" AND scorers = \"Brancão Couto 0\"" }
### INSTRUCTION Find the names of customers who have used either the service "Close a policy" or the service "Upgrade a policy". ### INPUT CREATE TABLE first_notification_of_loss (customer_id VARCHAR, service_id VARCHAR); CREATE TABLE customers (customer_name VARCHAR, customer_id VARCHAR); CREATE TABLE services (service_id VARCHAR, service_name VARCHAR) ### OUTPUT SELECT t1.customer_name FROM customers AS t1 JOIN first_notification_of_loss AS t2 ON t1.customer_id = t2.customer_id JOIN services AS t3 ON t2.service_id = t3.service_id WHERE t3.service_name = "Close a policy" OR t3.service_name = "Upgrade a policy"
{ "input": "CREATE TABLE first_notification_of_loss (customer_id VARCHAR, service_id VARCHAR); CREATE TABLE customers (customer_name VARCHAR, customer_id VARCHAR); CREATE TABLE services (service_id VARCHAR, service_name VARCHAR)", "instruction": "Find the names of customers who have used either the service \"Close a policy\" or the service \"Upgrade a policy\".", "output": "SELECT t1.customer_name FROM customers AS t1 JOIN first_notification_of_loss AS t2 ON t1.customer_id = t2.customer_id JOIN services AS t3 ON t2.service_id = t3.service_id WHERE t3.service_name = \"Close a policy\" OR t3.service_name = \"Upgrade a policy\"" }
### INSTRUCTION what is the sum of bronze when the rank is 5, the nation is poland and gold is less than 0? ### INPUT CREATE TABLE table_name_89 (bronze INTEGER, gold VARCHAR, rank VARCHAR, nation VARCHAR) ### OUTPUT SELECT SUM(bronze) FROM table_name_89 WHERE rank = 5 AND nation = "poland" AND gold < 0
{ "input": "CREATE TABLE table_name_89 (bronze INTEGER, gold VARCHAR, rank VARCHAR, nation VARCHAR)", "instruction": "what is the sum of bronze when the rank is 5, the nation is poland and gold is less than 0?", "output": "SELECT SUM(bronze) FROM table_name_89 WHERE rank = 5 AND nation = \"poland\" AND gold < 0" }
### INSTRUCTION what is the maximum ties played where player is josip palada category:articles with hcards ### INPUT CREATE TABLE table_10294071_1 (ties_played INTEGER, player VARCHAR) ### OUTPUT SELECT MAX(ties_played) FROM table_10294071_1 WHERE player = "Josip Palada Category:Articles with hCards"
{ "input": "CREATE TABLE table_10294071_1 (ties_played INTEGER, player VARCHAR)", "instruction": "what is the maximum ties played where player is josip palada category:articles with hcards", "output": "SELECT MAX(ties_played) FROM table_10294071_1 WHERE player = \"Josip Palada Category:Articles with hCards\"" }
### INSTRUCTION What is the average total with a Rank larger than 11, a Nation of switzerland, and a Silver smaller than 0? ### INPUT CREATE TABLE table_name_85 (total INTEGER, silver VARCHAR, rank VARCHAR, nation VARCHAR) ### OUTPUT SELECT AVG(total) FROM table_name_85 WHERE rank > 11 AND nation = "switzerland" AND silver < 0
{ "input": "CREATE TABLE table_name_85 (total INTEGER, silver VARCHAR, rank VARCHAR, nation VARCHAR)", "instruction": "What is the average total with a Rank larger than 11, a Nation of switzerland, and a Silver smaller than 0?", "output": "SELECT AVG(total) FROM table_name_85 WHERE rank > 11 AND nation = \"switzerland\" AND silver < 0" }
### INSTRUCTION list in alphabetic order all course names and their instructors' names in year 2008. ### INPUT CREATE TABLE course (title VARCHAR, course_id VARCHAR); CREATE TABLE teaches (course_id VARCHAR, id VARCHAR); CREATE TABLE instructor (name VARCHAR, id VARCHAR) ### OUTPUT SELECT T1.title, T3.name FROM course AS T1 JOIN teaches AS T2 ON T1.course_id = T2.course_id JOIN instructor AS T3 ON T2.id = T3.id WHERE YEAR = 2008 ORDER BY T1.title
{ "input": "CREATE TABLE course (title VARCHAR, course_id VARCHAR); CREATE TABLE teaches (course_id VARCHAR, id VARCHAR); CREATE TABLE instructor (name VARCHAR, id VARCHAR)", "instruction": "list in alphabetic order all course names and their instructors' names in year 2008.", "output": "SELECT T1.title, T3.name FROM course AS T1 JOIN teaches AS T2 ON T1.course_id = T2.course_id JOIN instructor AS T3 ON T2.id = T3.id WHERE YEAR = 2008 ORDER BY T1.title" }
### INSTRUCTION What Japanese prefecture has Ibaraki, Tsukuba? ### INPUT CREATE TABLE table_name_15 (japanese VARCHAR, prefecture VARCHAR, name VARCHAR) ### OUTPUT SELECT japanese FROM table_name_15 WHERE prefecture = "ibaraki" AND name = "tsukuba"
{ "input": "CREATE TABLE table_name_15 (japanese VARCHAR, prefecture VARCHAR, name VARCHAR)", "instruction": "What Japanese prefecture has Ibaraki, Tsukuba?", "output": "SELECT japanese FROM table_name_15 WHERE prefecture = \"ibaraki\" AND name = \"tsukuba\"" }
### INSTRUCTION What was the sensor with a resolution of 355x288 for a Naturalpoint Trackir 3? ### INPUT CREATE TABLE table_name_53 (sensor VARCHAR, sensor_resolution VARCHAR, camera VARCHAR) ### OUTPUT SELECT sensor FROM table_name_53 WHERE sensor_resolution = "355x288" AND camera = "naturalpoint trackir 3"
{ "input": "CREATE TABLE table_name_53 (sensor VARCHAR, sensor_resolution VARCHAR, camera VARCHAR)", "instruction": "What was the sensor with a resolution of 355x288 for a Naturalpoint Trackir 3?", "output": "SELECT sensor FROM table_name_53 WHERE sensor_resolution = \"355x288\" AND camera = \"naturalpoint trackir 3\"" }
### INSTRUCTION Who is the home team when the san francisco 49ers are visiting with a result of 42-14? ### INPUT CREATE TABLE table_name_92 (home_team VARCHAR, visiting_team VARCHAR, result VARCHAR) ### OUTPUT SELECT home_team FROM table_name_92 WHERE visiting_team = "san francisco 49ers" AND result = "42-14"
{ "input": "CREATE TABLE table_name_92 (home_team VARCHAR, visiting_team VARCHAR, result VARCHAR)", "instruction": "Who is the home team when the san francisco 49ers are visiting with a result of 42-14?", "output": "SELECT home_team FROM table_name_92 WHERE visiting_team = \"san francisco 49ers\" AND result = \"42-14\"" }
### INSTRUCTION What is the customer id, first and last name with least number of accounts. ### INPUT CREATE TABLE Customers_cards (customer_id VARCHAR); CREATE TABLE Customers (customer_first_name VARCHAR, customer_last_name VARCHAR, customer_id VARCHAR) ### OUTPUT SELECT T1.customer_id, T2.customer_first_name, T2.customer_last_name FROM Customers_cards AS T1 JOIN Customers AS T2 ON T1.customer_id = T2.customer_id GROUP BY T1.customer_id ORDER BY COUNT(*) LIMIT 1
{ "input": "CREATE TABLE Customers_cards (customer_id VARCHAR); CREATE TABLE Customers (customer_first_name VARCHAR, customer_last_name VARCHAR, customer_id VARCHAR)", "instruction": "What is the customer id, first and last name with least number of accounts.", "output": "SELECT T1.customer_id, T2.customer_first_name, T2.customer_last_name FROM Customers_cards AS T1 JOIN Customers AS T2 ON T1.customer_id = T2.customer_id GROUP BY T1.customer_id ORDER BY COUNT(*) LIMIT 1" }
### INSTRUCTION Who was the challenge winner in the episode that originally aired on January 28, 2009? ### INPUT CREATE TABLE table_24798489_1 (challenge_winner VARCHAR, original_airdate VARCHAR) ### OUTPUT SELECT challenge_winner FROM table_24798489_1 WHERE original_airdate = "January 28, 2009"
{ "input": "CREATE TABLE table_24798489_1 (challenge_winner VARCHAR, original_airdate VARCHAR)", "instruction": "Who was the challenge winner in the episode that originally aired on January 28, 2009?", "output": "SELECT challenge_winner FROM table_24798489_1 WHERE original_airdate = \"January 28, 2009\"" }
### INSTRUCTION What's the Elevator that has Elevated: 1378, September 18, an Order of Cardinal-Priest, and an Elector of Poncello Orsini? ### INPUT CREATE TABLE table_name_25 (elevator VARCHAR, elector VARCHAR, elevated VARCHAR, order VARCHAR) ### OUTPUT SELECT elevator FROM table_name_25 WHERE elevated = "1378, september 18" AND order = "cardinal-priest" AND elector = "poncello orsini"
{ "input": "CREATE TABLE table_name_25 (elevator VARCHAR, elector VARCHAR, elevated VARCHAR, order VARCHAR)", "instruction": "What's the Elevator that has Elevated: 1378, September 18, an Order of Cardinal-Priest, and an Elector of Poncello Orsini?", "output": "SELECT elevator FROM table_name_25 WHERE elevated = \"1378, september 18\" AND order = \"cardinal-priest\" AND elector = \"poncello orsini\"" }
### INSTRUCTION Tony P. Hall was the incumbent in the race between what two candidates? ### INPUT CREATE TABLE table_1341453_37 (candidates VARCHAR, incumbent VARCHAR) ### OUTPUT SELECT candidates FROM table_1341453_37 WHERE incumbent = "Tony P. Hall"
{ "input": "CREATE TABLE table_1341453_37 (candidates VARCHAR, incumbent VARCHAR)", "instruction": "Tony P. Hall was the incumbent in the race between what two candidates? ", "output": "SELECT candidates FROM table_1341453_37 WHERE incumbent = \"Tony P. Hall\"" }
### INSTRUCTION How much Quantity has a Type of 1′c1′ h2t? ### INPUT CREATE TABLE table_name_11 (quantity VARCHAR, type VARCHAR) ### OUTPUT SELECT COUNT(quantity) FROM table_name_11 WHERE type = "1′c1′ h2t"
{ "input": "CREATE TABLE table_name_11 (quantity VARCHAR, type VARCHAR)", "instruction": "How much Quantity has a Type of 1′c1′ h2t?", "output": "SELECT COUNT(quantity) FROM table_name_11 WHERE type = \"1′c1′ h2t\"" }
### INSTRUCTION What is the channel code and contact number of the customer contact channel that was active for the longest time? ### INPUT CREATE TABLE customer_contact_channels (channel_code VARCHAR, contact_number VARCHAR, active_to_date VARCHAR, active_from_date VARCHAR) ### OUTPUT SELECT channel_code, contact_number FROM customer_contact_channels WHERE active_to_date - active_from_date = (SELECT active_to_date - active_from_date FROM customer_contact_channels ORDER BY (active_to_date - active_from_date) DESC LIMIT 1)
{ "input": "CREATE TABLE customer_contact_channels (channel_code VARCHAR, contact_number VARCHAR, active_to_date VARCHAR, active_from_date VARCHAR)", "instruction": "What is the channel code and contact number of the customer contact channel that was active for the longest time?", "output": "SELECT channel_code, contact_number FROM customer_contact_channels WHERE active_to_date - active_from_date = (SELECT active_to_date - active_from_date FROM customer_contact_channels ORDER BY (active_to_date - active_from_date) DESC LIMIT 1)" }
### INSTRUCTION Who was in the Original West End Cast when the Original Broadway Cast was audrie neenan? ### INPUT CREATE TABLE table_name_1 (original_west_end_cast VARCHAR, original_broadway_cast VARCHAR) ### OUTPUT SELECT original_west_end_cast FROM table_name_1 WHERE original_broadway_cast = "audrie neenan"
{ "input": "CREATE TABLE table_name_1 (original_west_end_cast VARCHAR, original_broadway_cast VARCHAR)", "instruction": "Who was in the Original West End Cast when the Original Broadway Cast was audrie neenan?", "output": "SELECT original_west_end_cast FROM table_name_1 WHERE original_broadway_cast = \"audrie neenan\"" }
### INSTRUCTION Which Prominence (m) has an Elevation (m) of 3,095? ### INPUT CREATE TABLE table_name_67 (prominence__m_ INTEGER, elevation__m_ VARCHAR) ### OUTPUT SELECT MIN(prominence__m_) FROM table_name_67 WHERE elevation__m_ = 3 OFFSET 095
{ "input": "CREATE TABLE table_name_67 (prominence__m_ INTEGER, elevation__m_ VARCHAR)", "instruction": "Which Prominence (m) has an Elevation (m) of 3,095?", "output": "SELECT MIN(prominence__m_) FROM table_name_67 WHERE elevation__m_ = 3 OFFSET 095" }
### INSTRUCTION Which Laps have a Bike of kawasaki zx-6r, and a Time of +26.891? ### INPUT CREATE TABLE table_name_14 (laps INTEGER, bike VARCHAR, time VARCHAR) ### OUTPUT SELECT MIN(laps) FROM table_name_14 WHERE bike = "kawasaki zx-6r" AND time = "+26.891"
{ "input": "CREATE TABLE table_name_14 (laps INTEGER, bike VARCHAR, time VARCHAR)", "instruction": "Which Laps have a Bike of kawasaki zx-6r, and a Time of +26.891?", "output": "SELECT MIN(laps) FROM table_name_14 WHERE bike = \"kawasaki zx-6r\" AND time = \"+26.891\"" }
### INSTRUCTION Which #/ County has a Year Joined larger than 1926, and a Previous Conference of olympic? ### INPUT CREATE TABLE table_name_13 (_number___county VARCHAR, year_joined VARCHAR, previous_conference VARCHAR) ### OUTPUT SELECT _number___county FROM table_name_13 WHERE year_joined > 1926 AND previous_conference = "olympic"
{ "input": "CREATE TABLE table_name_13 (_number___county VARCHAR, year_joined VARCHAR, previous_conference VARCHAR)", "instruction": "Which #/ County has a Year Joined larger than 1926, and a Previous Conference of olympic?", "output": "SELECT _number___county FROM table_name_13 WHERE year_joined > 1926 AND previous_conference = \"olympic\"" }
### INSTRUCTION What Medal did James Odwori receive for Boxing in the 1970 Edinburgh Games? ### INPUT CREATE TABLE table_name_71 (medal VARCHAR, name VARCHAR, sport VARCHAR, games VARCHAR) ### OUTPUT SELECT medal FROM table_name_71 WHERE sport = "boxing" AND games = "1970 edinburgh" AND name = "james odwori"
{ "input": "CREATE TABLE table_name_71 (medal VARCHAR, name VARCHAR, sport VARCHAR, games VARCHAR)", "instruction": "What Medal did James Odwori receive for Boxing in the 1970 Edinburgh Games?", "output": "SELECT medal FROM table_name_71 WHERE sport = \"boxing\" AND games = \"1970 edinburgh\" AND name = \"james odwori\"" }
### INSTRUCTION Name the total number of swimsuits for evening gowns less than 8.21 and average of 8.453 with interview less than 9.09 ### INPUT CREATE TABLE table_name_54 (swimsuit VARCHAR, average VARCHAR, interview VARCHAR, evening_gown VARCHAR) ### OUTPUT SELECT COUNT(swimsuit) FROM table_name_54 WHERE interview < 9.09 AND evening_gown < 8.21 AND average = 8.453
{ "input": "CREATE TABLE table_name_54 (swimsuit VARCHAR, average VARCHAR, interview VARCHAR, evening_gown VARCHAR)", "instruction": "Name the total number of swimsuits for evening gowns less than 8.21 and average of 8.453 with interview less than 9.09", "output": "SELECT COUNT(swimsuit) FROM table_name_54 WHERE interview < 9.09 AND evening_gown < 8.21 AND average = 8.453" }
### INSTRUCTION Which Maximum episode premiered March 8, 2008? ### INPUT CREATE TABLE table_2140071_8 (episode INTEGER, premier_date VARCHAR) ### OUTPUT SELECT MAX(episode) FROM table_2140071_8 WHERE premier_date = "March 8, 2008"
{ "input": "CREATE TABLE table_2140071_8 (episode INTEGER, premier_date VARCHAR)", "instruction": "Which Maximum episode premiered March 8, 2008?", "output": "SELECT MAX(episode) FROM table_2140071_8 WHERE premier_date = \"March 8, 2008\"" }
### INSTRUCTION What pick was Scott Glennie from the Western hockey league ### INPUT CREATE TABLE table_name_62 (pick__number VARCHAR, league_from VARCHAR, player VARCHAR) ### OUTPUT SELECT pick__number FROM table_name_62 WHERE league_from = "western hockey league" AND player = "scott glennie"
{ "input": "CREATE TABLE table_name_62 (pick__number VARCHAR, league_from VARCHAR, player VARCHAR)", "instruction": "What pick was Scott Glennie from the Western hockey league", "output": "SELECT pick__number FROM table_name_62 WHERE league_from = \"western hockey league\" AND player = \"scott glennie\"" }
### INSTRUCTION Which Year has a Venue of atlanta, united states? ### INPUT CREATE TABLE table_name_13 (year VARCHAR, venue VARCHAR) ### OUTPUT SELECT year FROM table_name_13 WHERE venue = "atlanta, united states"
{ "input": "CREATE TABLE table_name_13 (year VARCHAR, venue VARCHAR)", "instruction": "Which Year has a Venue of atlanta, united states?", "output": "SELECT year FROM table_name_13 WHERE venue = \"atlanta, united states\"" }
### INSTRUCTION What English word has the same meaning as the German word "german"? ### INPUT CREATE TABLE table_name_3 (english VARCHAR) ### OUTPUT SELECT english FROM table_name_3 WHERE "german" = "german"
{ "input": "CREATE TABLE table_name_3 (english VARCHAR)", "instruction": "What English word has the same meaning as the German word \"german\"?", "output": "SELECT english FROM table_name_3 WHERE \"german\" = \"german\"" }
### INSTRUCTION Which Min press has none Death and seven Storm names? ### INPUT CREATE TABLE table_name_68 (min_press___mbar__ VARCHAR, deaths VARCHAR, storm_name VARCHAR) ### OUTPUT SELECT min_press___mbar__ FROM table_name_68 WHERE deaths = "none" AND storm_name = "seven"
{ "input": "CREATE TABLE table_name_68 (min_press___mbar__ VARCHAR, deaths VARCHAR, storm_name VARCHAR)", "instruction": "Which Min press has none Death and seven Storm names?", "output": "SELECT min_press___mbar__ FROM table_name_68 WHERE deaths = \"none\" AND storm_name = \"seven\"" }
### INSTRUCTION What is the lowest evening gown score a contestant with an average less than 8.23, an interview score of 8.11, and a swimsuit larger than 7.84 has? ### INPUT CREATE TABLE table_name_17 (evening_gown INTEGER, swimsuit VARCHAR, average VARCHAR, interview VARCHAR) ### OUTPUT SELECT MIN(evening_gown) FROM table_name_17 WHERE average < 8.23 AND interview = 8.11 AND swimsuit > 7.84
{ "input": "CREATE TABLE table_name_17 (evening_gown INTEGER, swimsuit VARCHAR, average VARCHAR, interview VARCHAR)", "instruction": "What is the lowest evening gown score a contestant with an average less than 8.23, an interview score of 8.11, and a swimsuit larger than 7.84 has?", "output": "SELECT MIN(evening_gown) FROM table_name_17 WHERE average < 8.23 AND interview = 8.11 AND swimsuit > 7.84" }
### INSTRUCTION What was the host city of the 8th edition in the the host country of Croatia? ### INPUT CREATE TABLE table_26669939_1 (host_city VARCHAR, host_country VARCHAR, edition VARCHAR) ### OUTPUT SELECT host_city FROM table_26669939_1 WHERE host_country = "Croatia" AND edition = "8th"
{ "input": "CREATE TABLE table_26669939_1 (host_city VARCHAR, host_country VARCHAR, edition VARCHAR)", "instruction": "What was the host city of the 8th edition in the the host country of Croatia?", "output": "SELECT host_city FROM table_26669939_1 WHERE host_country = \"Croatia\" AND edition = \"8th\"" }
### INSTRUCTION What types of stations are located in Cebu? ### INPUT CREATE TABLE table_28794440_1 (station_type VARCHAR, location VARCHAR) ### OUTPUT SELECT station_type FROM table_28794440_1 WHERE location = "Cebu"
{ "input": "CREATE TABLE table_28794440_1 (station_type VARCHAR, location VARCHAR)", "instruction": "What types of stations are located in Cebu?", "output": "SELECT station_type FROM table_28794440_1 WHERE location = \"Cebu\"" }
### INSTRUCTION How many attendance numbers are associated with the site of Veterans Stadium before week 1? ### INPUT CREATE TABLE table_name_59 (attendance VARCHAR, game_site VARCHAR, week VARCHAR) ### OUTPUT SELECT COUNT(attendance) FROM table_name_59 WHERE game_site = "veterans stadium" AND week < 1
{ "input": "CREATE TABLE table_name_59 (attendance VARCHAR, game_site VARCHAR, week VARCHAR)", "instruction": "How many attendance numbers are associated with the site of Veterans Stadium before week 1?", "output": "SELECT COUNT(attendance) FROM table_name_59 WHERE game_site = \"veterans stadium\" AND week < 1" }
### INSTRUCTION What was the score at Bernardo O'Higgins Cup on May 7, 1961? ### INPUT CREATE TABLE table_name_94 (score VARCHAR, competition VARCHAR, date VARCHAR) ### OUTPUT SELECT score FROM table_name_94 WHERE competition = "bernardo o'higgins cup" AND date = "may 7, 1961"
{ "input": "CREATE TABLE table_name_94 (score VARCHAR, competition VARCHAR, date VARCHAR)", "instruction": "What was the score at Bernardo O'Higgins Cup on May 7, 1961?", "output": "SELECT score FROM table_name_94 WHERE competition = \"bernardo o'higgins cup\" AND date = \"may 7, 1961\"" }
### INSTRUCTION Show the names of artworks in ascending order of the year they are nominated in. ### INPUT CREATE TABLE artwork (Name VARCHAR, Artwork_ID VARCHAR); CREATE TABLE nomination (Artwork_ID VARCHAR, Festival_ID VARCHAR); CREATE TABLE festival_detail (Festival_ID VARCHAR, Year VARCHAR) ### OUTPUT SELECT T2.Name FROM nomination AS T1 JOIN artwork AS T2 ON T1.Artwork_ID = T2.Artwork_ID JOIN festival_detail AS T3 ON T1.Festival_ID = T3.Festival_ID ORDER BY T3.Year
{ "input": "CREATE TABLE artwork (Name VARCHAR, Artwork_ID VARCHAR); CREATE TABLE nomination (Artwork_ID VARCHAR, Festival_ID VARCHAR); CREATE TABLE festival_detail (Festival_ID VARCHAR, Year VARCHAR)", "instruction": "Show the names of artworks in ascending order of the year they are nominated in.", "output": "SELECT T2.Name FROM nomination AS T1 JOIN artwork AS T2 ON T1.Artwork_ID = T2.Artwork_ID JOIN festival_detail AS T3 ON T1.Festival_ID = T3.Festival_ID ORDER BY T3.Year" }