text
stringlengths
150
1.06k
source
dict
### QUESTION What are the date of ceremony of music festivals with category "Best Song" and result "Awarded"? ### CONTEXT CREATE TABLE music_festival (Date_of_ceremony VARCHAR, Category VARCHAR, RESULT VARCHAR) ### ANSWER SELECT Date_of_ceremony FROM music_festival WHERE Category = "Best Song" AND RESULT = "Awarded"</s>
{ "answer": "SELECT Date_of_ceremony FROM music_festival WHERE Category = \"Best Song\" AND RESULT = \"Awarded\"", "context": "CREATE TABLE music_festival (Date_of_ceremony VARCHAR, Category VARCHAR, RESULT VARCHAR)", "question": "What are the date of ceremony of music festivals with category \"Best Song\" and result \"Awarded\"?" }
### QUESTION What is the highest taijijian with a 9.87 taijiquan and a total less than 19.77? ### CONTEXT CREATE TABLE table_name_20 (taijijian INTEGER, taijiquan VARCHAR, total VARCHAR) ### ANSWER SELECT MAX(taijijian) FROM table_name_20 WHERE taijiquan = 9.87 AND total < 19.77</s>
{ "answer": "SELECT MAX(taijijian) FROM table_name_20 WHERE taijiquan = 9.87 AND total < 19.77", "context": "CREATE TABLE table_name_20 (taijijian INTEGER, taijiquan VARCHAR, total VARCHAR)", "question": "What is the highest taijijian with a 9.87 taijiquan and a total less than 19.77?" }
### QUESTION What are the issue dates of volumes associated with the artist aged 23 or younger? ### CONTEXT CREATE TABLE volume (Artist_ID VARCHAR); CREATE TABLE artist (Artist_ID VARCHAR, age VARCHAR) ### ANSWER SELECT Issue_Date FROM artist AS T1 JOIN volume AS T2 ON T1.Artist_ID = T2.Artist_ID WHERE T1.age <= 23</s>
{ "answer": "SELECT Issue_Date FROM artist AS T1 JOIN volume AS T2 ON T1.Artist_ID = T2.Artist_ID WHERE T1.age <= 23", "context": "CREATE TABLE volume (Artist_ID VARCHAR); CREATE TABLE artist (Artist_ID VARCHAR, age VARCHAR)", "question": "What are the issue dates of volumes associated with the artist aged 23 or younger?" }
### QUESTION Felicia Taylor was cyber girl in week 3, so who was the cyber girl in week 5? ### CONTEXT CREATE TABLE table_name_95 (week_5 VARCHAR, week_3 VARCHAR) ### ANSWER SELECT week_5 FROM table_name_95 WHERE week_3 = "felicia taylor"</s>
{ "answer": "SELECT week_5 FROM table_name_95 WHERE week_3 = \"felicia taylor\"", "context": "CREATE TABLE table_name_95 (week_5 VARCHAR, week_3 VARCHAR)", "question": "Felicia Taylor was cyber girl in week 3, so who was the cyber girl in week 5?" }
### QUESTION List the names of countries whose language is not "German". ### CONTEXT CREATE TABLE country (Name VARCHAR, Languages VARCHAR) ### ANSWER SELECT Name FROM country WHERE Languages <> "German"</s>
{ "answer": "SELECT Name FROM country WHERE Languages <> \"German\"", "context": "CREATE TABLE country (Name VARCHAR, Languages VARCHAR)", "question": "List the names of countries whose language is not \"German\"." }
### QUESTION When was the Result of 3–2, with a Score of 6–0, 6–4? ### CONTEXT CREATE TABLE table_name_72 (date VARCHAR, result VARCHAR, score VARCHAR) ### ANSWER SELECT date FROM table_name_72 WHERE result = "3–2" AND score = "6–0, 6–4"</s>
{ "answer": "SELECT date FROM table_name_72 WHERE result = \"3–2\" AND score = \"6–0, 6–4\"", "context": "CREATE TABLE table_name_72 (date VARCHAR, result VARCHAR, score VARCHAR)", "question": "When was the Result of 3–2, with a Score of 6–0, 6–4?" }
### QUESTION Show the names of countries that have more than one roller coaster. ### CONTEXT CREATE TABLE roller_coaster (Country_ID VARCHAR); CREATE TABLE country (Name VARCHAR, Country_ID VARCHAR) ### ANSWER SELECT T1.Name FROM country AS T1 JOIN roller_coaster AS T2 ON T1.Country_ID = T2.Country_ID GROUP BY T1.Name HAVING COUNT(*) > 1</s>
{ "answer": "SELECT T1.Name FROM country AS T1 JOIN roller_coaster AS T2 ON T1.Country_ID = T2.Country_ID GROUP BY T1.Name HAVING COUNT(*) > 1", "context": "CREATE TABLE roller_coaster (Country_ID VARCHAR); CREATE TABLE country (Name VARCHAR, Country_ID VARCHAR)", "question": "Show the names of countries that have more than one roller coaster." }
### QUESTION Show the name and population of the country that has the highest roller coaster. ### CONTEXT CREATE TABLE roller_coaster (Country_ID VARCHAR, Height VARCHAR); CREATE TABLE country (Name VARCHAR, population VARCHAR, Country_ID VARCHAR) ### ANSWER SELECT T1.Name, T1.population FROM country AS T1 JOIN roller_coaster AS T2 ON T1.Country_ID = T2.Country_ID ORDER BY T2.Height DESC LIMIT 1</s>
{ "answer": "SELECT T1.Name, T1.population FROM country AS T1 JOIN roller_coaster AS T2 ON T1.Country_ID = T2.Country_ID ORDER BY T2.Height DESC LIMIT 1", "context": "CREATE TABLE roller_coaster (Country_ID VARCHAR, Height VARCHAR); CREATE TABLE country (Name VARCHAR, population VARCHAR, Country_ID VARCHAR)", "question": "Show the name and population of the country that has the highest roller coaster." }
### QUESTION What are the country names, area and population which has both roller coasters with speed higher ### CONTEXT CREATE TABLE country (name VARCHAR, area VARCHAR, population VARCHAR, Country_ID VARCHAR); CREATE TABLE roller_coaster (Country_ID VARCHAR, speed INTEGER) ### ANSWER SELECT T1.name, T1.area, T1.population FROM country AS T1 JOIN roller_coaster AS T2 ON T1.Country_ID = T2.Country_ID WHERE T2.speed > 60 INTERSECT SELECT T1.name, T1.area, T1.population FROM country AS T1 JOIN roller_coaster AS T2 ON T1.Country_ID = T2.Country_ID WHERE T2.speed < 55</s>
{ "answer": "SELECT T1.name, T1.area, T1.population FROM country AS T1 JOIN roller_coaster AS T2 ON T1.Country_ID = T2.Country_ID WHERE T2.speed > 60 INTERSECT SELECT T1.name, T1.area, T1.population FROM country AS T1 JOIN roller_coaster AS T2 ON T1.Country_ID = T2.Country_ID WHERE T2.speed < 55", "context": "CREATE TABLE country (name VARCHAR, area VARCHAR, population VARCHAR, Country_ID VARCHAR); CREATE TABLE roller_coaster (Country_ID VARCHAR, speed INTEGER)", "question": "What are the country names, area and population which has both roller coasters with speed higher" }
### QUESTION What time was achieved on Saturday 29th August by the rider who recorded 24' 17.26 93.208mph on Monday 24th August? ### CONTEXT CREATE TABLE table_23465864_4 (sat_29_aug VARCHAR, mon_24_aug VARCHAR) ### ANSWER SELECT sat_29_aug FROM table_23465864_4 WHERE mon_24_aug = "24' 17.26 93.208mph"</s>
{ "answer": "SELECT sat_29_aug FROM table_23465864_4 WHERE mon_24_aug = \"24' 17.26 93.208mph\"", "context": "CREATE TABLE table_23465864_4 (sat_29_aug VARCHAR, mon_24_aug VARCHAR)", "question": "What time was achieved on Saturday 29th August by the rider who recorded 24' 17.26 93.208mph on Monday 24th August?" }
### QUESTION Find the name of captains whose rank are either Midshipman or Lieutenant. ### CONTEXT CREATE TABLE captain (name VARCHAR, rank VARCHAR) ### ANSWER SELECT name FROM captain WHERE rank = 'Midshipman' OR rank = 'Lieutenant'</s>
{ "answer": "SELECT name FROM captain WHERE rank = 'Midshipman' OR rank = 'Lieutenant'", "context": "CREATE TABLE captain (name VARCHAR, rank VARCHAR)", "question": "Find the name of captains whose rank are either Midshipman or Lieutenant." }
### QUESTION What is the Title of the Pye Label mono LP release? ### CONTEXT CREATE TABLE table_name_18 (title VARCHAR, format VARCHAR, label VARCHAR) ### ANSWER SELECT title FROM table_name_18 WHERE format = "mono lp" AND label = "pye"</s>
{ "answer": "SELECT title FROM table_name_18 WHERE format = \"mono lp\" AND label = \"pye\"", "context": "CREATE TABLE table_name_18 (title VARCHAR, format VARCHAR, label VARCHAR)", "question": "What is the Title of the Pye Label mono LP release?" }
### QUESTION What is the total area with the census ranking of 3,129 of 5,008, and a Population smaller than 460? ### CONTEXT CREATE TABLE table_name_60 (area_km_2 VARCHAR, census_ranking VARCHAR, population VARCHAR) ### ANSWER SELECT COUNT(area_km_2) FROM table_name_60 WHERE census_ranking = "3,129 of 5,008" AND population < 460</s>
{ "answer": "SELECT COUNT(area_km_2) FROM table_name_60 WHERE census_ranking = \"3,129 of 5,008\" AND population < 460", "context": "CREATE TABLE table_name_60 (area_km_2 VARCHAR, census_ranking VARCHAR, population VARCHAR)", "question": "What is the total area with the census ranking of 3,129 of 5,008, and a Population smaller than 460?" }
### QUESTION What is the total area with the Census Ranking of 3,129 of 5,008, and a Population larger than 460? ### CONTEXT CREATE TABLE table_name_66 (area_km_2 VARCHAR, census_ranking VARCHAR, population VARCHAR) ### ANSWER SELECT COUNT(area_km_2) FROM table_name_66 WHERE census_ranking = "3,129 of 5,008" AND population > 460</s>
{ "answer": "SELECT COUNT(area_km_2) FROM table_name_66 WHERE census_ranking = \"3,129 of 5,008\" AND population > 460", "context": "CREATE TABLE table_name_66 (area_km_2 VARCHAR, census_ranking VARCHAR, population VARCHAR)", "question": "What is the total area with the Census Ranking of 3,129 of 5,008, and a Population larger than 460?" }
### QUESTION What's the service number of the Pune Duronto train that departures at 21:35? ### CONTEXT CREATE TABLE table_23477312_1 (service VARCHAR, train_name VARCHAR, departure VARCHAR) ### ANSWER SELECT service FROM table_23477312_1 WHERE train_name = "Pune Duronto" AND departure = "21:35"</s>
{ "answer": "SELECT service FROM table_23477312_1 WHERE train_name = \"Pune Duronto\" AND departure = \"21:35\"", "context": "CREATE TABLE table_23477312_1 (service VARCHAR, train_name VARCHAR, departure VARCHAR)", "question": "What's the service number of the Pune Duronto train that departures at 21:35?" }
### QUESTION What's the name of the train that goes to Bhubaneswar? ### CONTEXT CREATE TABLE table_23477312_1 (train_name VARCHAR, destination VARCHAR) ### ANSWER SELECT train_name FROM table_23477312_1 WHERE destination = "Bhubaneswar"</s>
{ "answer": "SELECT train_name FROM table_23477312_1 WHERE destination = \"Bhubaneswar\"", "context": "CREATE TABLE table_23477312_1 (train_name VARCHAR, destination VARCHAR)", "question": "What's the name of the train that goes to Bhubaneswar?" }
### QUESTION Find the name of the ships that have more than one captain. ### CONTEXT CREATE TABLE captain (ship_id VARCHAR); CREATE TABLE ship (name VARCHAR, ship_id VARCHAR) ### ANSWER SELECT t1.name FROM ship AS t1 JOIN captain AS t2 ON t1.ship_id = t2.ship_id GROUP BY t2.ship_id HAVING COUNT(*) > 1</s>
{ "answer": "SELECT t1.name FROM ship AS t1 JOIN captain AS t2 ON t1.ship_id = t2.ship_id GROUP BY t2.ship_id HAVING COUNT(*) > 1", "context": "CREATE TABLE captain (ship_id VARCHAR); CREATE TABLE ship (name VARCHAR, ship_id VARCHAR)", "question": "Find the name of the ships that have more than one captain." }
### QUESTION Find the name of the ship that is steered by the youngest captain. ### CONTEXT CREATE TABLE ship (name VARCHAR, ship_id VARCHAR); CREATE TABLE captain (ship_id VARCHAR, age VARCHAR) ### ANSWER SELECT t1.name FROM ship AS t1 JOIN captain AS t2 ON t1.ship_id = t2.ship_id ORDER BY t2.age LIMIT 1</s>
{ "answer": "SELECT t1.name FROM ship AS t1 JOIN captain AS t2 ON t1.ship_id = t2.ship_id ORDER BY t2.age LIMIT 1", "context": "CREATE TABLE ship (name VARCHAR, ship_id VARCHAR); CREATE TABLE captain (ship_id VARCHAR, age VARCHAR)", "question": "Find the name of the ship that is steered by the youngest captain." }
### QUESTION Find the name of the ships that are steered by both a captain with Midshipman rank and a captain with Lieutenant rank. ### CONTEXT CREATE TABLE ship (name VARCHAR, ship_id VARCHAR); CREATE TABLE captain (ship_id VARCHAR, rank VARCHAR) ### ANSWER SELECT t1.name FROM ship AS t1 JOIN captain AS t2 ON t1.ship_id = t2.ship_id WHERE t2.rank = 'Midshipman' INTERSECT SELECT t1.name FROM ship AS t1 JOIN captain AS t2 ON t1.ship_id = t2.ship_id WHERE t2.rank = 'Lieutenant'</s>
{ "answer": "SELECT t1.name FROM ship AS t1 JOIN captain AS t2 ON t1.ship_id = t2.ship_id WHERE t2.rank = 'Midshipman' INTERSECT SELECT t1.name FROM ship AS t1 JOIN captain AS t2 ON t1.ship_id = t2.ship_id WHERE t2.rank = 'Lieutenant'", "context": "CREATE TABLE ship (name VARCHAR, ship_id VARCHAR); CREATE TABLE captain (ship_id VARCHAR, rank VARCHAR)", "question": "Find the name of the ships that are steered by both a captain with Midshipman rank and a captain with Lieutenant rank." }
### QUESTION Find the cities which were once a host city after 2010? ### CONTEXT CREATE TABLE city (city VARCHAR, city_id VARCHAR); CREATE TABLE hosting_city (host_city VARCHAR, year INTEGER) ### ANSWER SELECT T1.city FROM city AS T1 JOIN hosting_city AS T2 ON T1.city_id = T2.host_city WHERE T2.year > 2010</s>
{ "answer": "SELECT T1.city FROM city AS T1 JOIN hosting_city AS T2 ON T1.city_id = T2.host_city WHERE T2.year > 2010", "context": "CREATE TABLE city (city VARCHAR, city_id VARCHAR); CREATE TABLE hosting_city (host_city VARCHAR, year INTEGER)", "question": "Find the cities which were once a host city after 2010?" }
### QUESTION What is the venue of the competition "1994 FIFA World Cup qualification" hosted by "Nanjing ( Jiangsu )"? ### CONTEXT CREATE TABLE city (city_id VARCHAR, city VARCHAR); CREATE TABLE MATCH (venue VARCHAR, match_id VARCHAR, competition VARCHAR); CREATE TABLE hosting_city (host_city VARCHAR, match_id VARCHAR) ### ANSWER SELECT T3.venue FROM city AS T1 JOIN hosting_city AS T2 ON T1.city_id = T2.host_city JOIN MATCH AS T3 ON T2.match_id = T3.match_id WHERE T1.city = "Nanjing ( Jiangsu )" AND T3.competition = "1994 FIFA World Cup qualification"</s>
{ "answer": "SELECT T3.venue FROM city AS T1 JOIN hosting_city AS T2 ON T1.city_id = T2.host_city JOIN MATCH AS T3 ON T2.match_id = T3.match_id WHERE T1.city = \"Nanjing ( Jiangsu )\" AND T3.competition = \"1994 FIFA World Cup qualification\"", "context": "CREATE TABLE city (city_id VARCHAR, city VARCHAR); CREATE TABLE MATCH (venue VARCHAR, match_id VARCHAR, competition VARCHAR); CREATE TABLE hosting_city (host_city VARCHAR, match_id VARCHAR)", "question": "What is the venue of the competition \"1994 FIFA World Cup qualification\" hosted by \"Nanjing ( Jiangsu )\"?" }
### QUESTION Give me the temperature of Shanghai in January. ### CONTEXT CREATE TABLE city (city_id VARCHAR, city VARCHAR); CREATE TABLE temperature (Jan VARCHAR, city_id VARCHAR) ### ANSWER SELECT T2.Jan FROM city AS T1 JOIN temperature AS T2 ON T1.city_id = T2.city_id WHERE T1.city = "Shanghai"</s>
{ "answer": "SELECT T2.Jan FROM city AS T1 JOIN temperature AS T2 ON T1.city_id = T2.city_id WHERE T1.city = \"Shanghai\"", "context": "CREATE TABLE city (city_id VARCHAR, city VARCHAR); CREATE TABLE temperature (Jan VARCHAR, city_id VARCHAR)", "question": "Give me the temperature of Shanghai in January." }
### QUESTION What is every score at the location of Verizon Center and points of 68? ### CONTEXT CREATE TABLE table_23486853_8 (score VARCHAR, location VARCHAR, points VARCHAR) ### ANSWER SELECT score FROM table_23486853_8 WHERE location = "Verizon Center" AND points = 68</s>
{ "answer": "SELECT score FROM table_23486853_8 WHERE location = \"Verizon Center\" AND points = 68", "context": "CREATE TABLE table_23486853_8 (score VARCHAR, location VARCHAR, points VARCHAR)", "question": "What is every score at the location of Verizon Center and points of 68?" }
### QUESTION Show the Thai name of wan phruehatsabodi? ### CONTEXT CREATE TABLE table_name_29 (thai_name VARCHAR, transcription VARCHAR) ### ANSWER SELECT thai_name FROM table_name_29 WHERE transcription = "wan phruehatsabodi"</s>
{ "answer": "SELECT thai_name FROM table_name_29 WHERE transcription = \"wan phruehatsabodi\"", "context": "CREATE TABLE table_name_29 (thai_name VARCHAR, transcription VARCHAR)", "question": "Show the Thai name of wan phruehatsabodi?" }
### QUESTION How many officers o/s were there on the day when the number of USAAF was 2373882? ### CONTEXT CREATE TABLE table_23508196_2 (officers_o_s INTEGER, total_usaaf VARCHAR) ### ANSWER SELECT MAX(officers_o_s) FROM table_23508196_2 WHERE total_usaaf = 2373882</s>
{ "answer": "SELECT MAX(officers_o_s) FROM table_23508196_2 WHERE total_usaaf = 2373882", "context": "CREATE TABLE table_23508196_2 (officers_o_s INTEGER, total_usaaf VARCHAR)", "question": "How many officers o/s were there on the day when the number of USAAF was 2373882?" }
### QUESTION Give me a list of cities whose temperature in Mar is lower than that in July and which have also served as host cities? ### CONTEXT CREATE TABLE city (city VARCHAR, city_id VARCHAR); CREATE TABLE hosting_city (host_city VARCHAR); CREATE TABLE temperature (city_id VARCHAR, Mar INTEGER, Jul VARCHAR) ### ANSWER SELECT T1.city FROM city AS T1 JOIN temperature AS T2 ON T1.city_id = T2.city_id WHERE T2.Mar < T2.Jul INTERSECT SELECT T3.city FROM city AS T3 JOIN hosting_city AS T4 ON T3.city_id = T4.host_city</s>
{ "answer": "SELECT T1.city FROM city AS T1 JOIN temperature AS T2 ON T1.city_id = T2.city_id WHERE T2.Mar < T2.Jul INTERSECT SELECT T3.city FROM city AS T3 JOIN hosting_city AS T4 ON T3.city_id = T4.host_city", "context": "CREATE TABLE city (city VARCHAR, city_id VARCHAR); CREATE TABLE hosting_city (host_city VARCHAR); CREATE TABLE temperature (city_id VARCHAR, Mar INTEGER, Jul VARCHAR)", "question": "Give me a list of cities whose temperature in Mar is lower than that in July and which have also served as host cities?" }
### QUESTION Give me a list of cities whose temperature in Mar is lower than that in Dec and which have never been host cities. ### CONTEXT CREATE TABLE city (city VARCHAR, city_id VARCHAR); CREATE TABLE hosting_city (host_city VARCHAR); CREATE TABLE temperature (city_id VARCHAR, Mar INTEGER, Dec VARCHAR) ### ANSWER SELECT T1.city FROM city AS T1 JOIN temperature AS T2 ON T1.city_id = T2.city_id WHERE T2.Mar < T2.Dec EXCEPT SELECT T3.city FROM city AS T3 JOIN hosting_city AS T4 ON T3.city_id = T4.host_city</s>
{ "answer": "SELECT T1.city FROM city AS T1 JOIN temperature AS T2 ON T1.city_id = T2.city_id WHERE T2.Mar < T2.Dec EXCEPT SELECT T3.city FROM city AS T3 JOIN hosting_city AS T4 ON T3.city_id = T4.host_city", "context": "CREATE TABLE city (city VARCHAR, city_id VARCHAR); CREATE TABLE hosting_city (host_city VARCHAR); CREATE TABLE temperature (city_id VARCHAR, Mar INTEGER, Dec VARCHAR)", "question": "Give me a list of cities whose temperature in Mar is lower than that in Dec and which have never been host cities." }
### QUESTION Give me a list of cities whose temperature in Feb is higher than that in Jun or cities that were once host cities? ### CONTEXT CREATE TABLE city (city VARCHAR, city_id VARCHAR); CREATE TABLE hosting_city (host_city VARCHAR); CREATE TABLE temperature (city_id VARCHAR, Feb INTEGER, Jun VARCHAR) ### ANSWER SELECT T1.city FROM city AS T1 JOIN temperature AS T2 ON T1.city_id = T2.city_id WHERE T2.Feb > T2.Jun UNION SELECT T3.city FROM city AS T3 JOIN hosting_city AS T4 ON T3.city_id = T4.host_city</s>
{ "answer": "SELECT T1.city FROM city AS T1 JOIN temperature AS T2 ON T1.city_id = T2.city_id WHERE T2.Feb > T2.Jun UNION SELECT T3.city FROM city AS T3 JOIN hosting_city AS T4 ON T3.city_id = T4.host_city", "context": "CREATE TABLE city (city VARCHAR, city_id VARCHAR); CREATE TABLE hosting_city (host_city VARCHAR); CREATE TABLE temperature (city_id VARCHAR, Feb INTEGER, Jun VARCHAR)", "question": "Give me a list of cities whose temperature in Feb is higher than that in Jun or cities that were once host cities?" }
### QUESTION Please give me a list of cities whose regional population is over 8000000 or under 5000000. ### CONTEXT CREATE TABLE city (city VARCHAR, regional_population INTEGER) ### ANSWER SELECT city FROM city WHERE regional_population > 10000000 UNION SELECT city FROM city WHERE regional_population < 5000000</s>
{ "answer": "SELECT city FROM city WHERE regional_population > 10000000 UNION SELECT city FROM city WHERE regional_population < 5000000", "context": "CREATE TABLE city (city VARCHAR, regional_population INTEGER)", "question": "Please give me a list of cities whose regional population is over 8000000 or under 5000000." }
### QUESTION What year had Best Actor in a Musical as a category? ### CONTEXT CREATE TABLE table_name_15 (year INTEGER, category VARCHAR) ### ANSWER SELECT SUM(year) FROM table_name_15 WHERE category = "best actor in a musical"</s>
{ "answer": "SELECT SUM(year) FROM table_name_15 WHERE category = \"best actor in a musical\"", "context": "CREATE TABLE table_name_15 (year INTEGER, category VARCHAR)", "question": "What year had Best Actor in a Musical as a category?" }
### QUESTION What are the GDP and population of the city that already served as a host more than once? ### CONTEXT CREATE TABLE hosting_city (host_city VARCHAR); CREATE TABLE city (city_id VARCHAR) ### ANSWER SELECT t1.gdp, t1.Regional_Population FROM city AS T1 JOIN hosting_city AS T2 ON T1.city_id = T2.host_city GROUP BY t2.Host_City HAVING COUNT(*) > 1</s>
{ "answer": "SELECT t1.gdp, t1.Regional_Population FROM city AS T1 JOIN hosting_city AS T2 ON T1.city_id = T2.host_city GROUP BY t2.Host_City HAVING COUNT(*) > 1", "context": "CREATE TABLE hosting_city (host_city VARCHAR); CREATE TABLE city (city_id VARCHAR)", "question": "What are the GDP and population of the city that already served as a host more than once?" }
### QUESTION List every individual's first name, middle name and last name in alphabetical order by last name. ### CONTEXT CREATE TABLE individuals (individual_first_name VARCHAR, individual_middle_name VARCHAR, individual_last_name VARCHAR) ### ANSWER SELECT individual_first_name, individual_middle_name, individual_last_name FROM individuals ORDER BY individual_last_name</s>
{ "answer": "SELECT individual_first_name, individual_middle_name, individual_last_name FROM individuals ORDER BY individual_last_name", "context": "CREATE TABLE individuals (individual_first_name VARCHAR, individual_middle_name VARCHAR, individual_last_name VARCHAR)", "question": "List every individual's first name, middle name and last name in alphabetical order by last name." }
### QUESTION If the speaker is Munu Adhi (2) K. Rajaram, what is the election year maximum? ### CONTEXT CREATE TABLE table_23512864_4 (election_year INTEGER, speaker VARCHAR) ### ANSWER SELECT MAX(election_year) FROM table_23512864_4 WHERE speaker = "Munu Adhi (2) K. Rajaram"</s>
{ "answer": "SELECT MAX(election_year) FROM table_23512864_4 WHERE speaker = \"Munu Adhi (2) K. Rajaram\"", "context": "CREATE TABLE table_23512864_4 (election_year INTEGER, speaker VARCHAR)", "question": "If the speaker is Munu Adhi (2) K. Rajaram, what is the election year maximum?" }
### QUESTION Find the name of the most popular party form. ### CONTEXT CREATE TABLE party_forms (form_id VARCHAR); CREATE TABLE forms (form_name VARCHAR, form_id VARCHAR) ### ANSWER SELECT t1.form_name FROM forms AS t1 JOIN party_forms AS t2 ON t1.form_id = t2.form_id GROUP BY t2.form_id ORDER BY COUNT(*) DESC LIMIT 1</s>
{ "answer": "SELECT t1.form_name FROM forms AS t1 JOIN party_forms AS t2 ON t1.form_id = t2.form_id GROUP BY t2.form_id ORDER BY COUNT(*) DESC LIMIT 1", "context": "CREATE TABLE party_forms (form_id VARCHAR); CREATE TABLE forms (form_name VARCHAR, form_id VARCHAR)", "question": "Find the name of the most popular party form." }
### QUESTION Which country has a to par of +2 for Bernhard Langer? ### CONTEXT CREATE TABLE table_name_3 (country VARCHAR, to_par VARCHAR, player VARCHAR) ### ANSWER SELECT country FROM table_name_3 WHERE to_par = "+2" AND player = "bernhard langer"</s>
{ "answer": "SELECT country FROM table_name_3 WHERE to_par = \"+2\" AND player = \"bernhard langer\"", "context": "CREATE TABLE table_name_3 (country VARCHAR, to_par VARCHAR, player VARCHAR)", "question": "Which country has a to par of +2 for Bernhard Langer?" }
### QUESTION Find the emails of parties with the most popular party form. ### CONTEXT CREATE TABLE party_forms (form_id VARCHAR); CREATE TABLE parties (party_email VARCHAR, party_id VARCHAR); CREATE TABLE party_forms (party_id VARCHAR, form_id VARCHAR) ### ANSWER SELECT t1.party_email FROM parties AS t1 JOIN party_forms AS t2 ON t1.party_id = t2.party_id WHERE t2.form_id = (SELECT form_id FROM party_forms GROUP BY form_id ORDER BY COUNT(*) DESC LIMIT 1)</s>
{ "answer": "SELECT t1.party_email FROM parties AS t1 JOIN party_forms AS t2 ON t1.party_id = t2.party_id WHERE t2.form_id = (SELECT form_id FROM party_forms GROUP BY form_id ORDER BY COUNT(*) DESC LIMIT 1)", "context": "CREATE TABLE party_forms (form_id VARCHAR); CREATE TABLE parties (party_email VARCHAR, party_id VARCHAR); CREATE TABLE party_forms (party_id VARCHAR, form_id VARCHAR)", "question": "Find the emails of parties with the most popular party form." }
### QUESTION What Social AO has a President of harm van leeuwen? ### CONTEXT CREATE TABLE table_name_68 (social_ao VARCHAR, president VARCHAR) ### ANSWER SELECT social_ao FROM table_name_68 WHERE president = "harm van leeuwen"</s>
{ "answer": "SELECT social_ao FROM table_name_68 WHERE president = \"harm van leeuwen\"", "context": "CREATE TABLE table_name_68 (social_ao VARCHAR, president VARCHAR)", "question": "What Social AO has a President of harm van leeuwen?" }
### QUESTION What is the rad number for the dead end in rank 22? ### CONTEXT CREATE TABLE table_name_75 (road_number VARCHAR, type VARCHAR, rank VARCHAR) ### ANSWER SELECT road_number FROM table_name_75 WHERE type = "dead end" AND rank = "22"</s>
{ "answer": "SELECT road_number FROM table_name_75 WHERE type = \"dead end\" AND rank = \"22\"", "context": "CREATE TABLE table_name_75 (road_number VARCHAR, type VARCHAR, rank VARCHAR)", "question": "What is the rad number for the dead end in rank 22?" }
### QUESTION Find the last name of the latest contact individual of the organization "Labour Party". ### CONTEXT CREATE TABLE organizations (organization_id VARCHAR, organization_name VARCHAR); CREATE TABLE individuals (individual_last_name VARCHAR, individual_id VARCHAR); CREATE TABLE organization_contact_individuals (organization_id VARCHAR, individual_id VARCHAR, date_contact_to VARCHAR) ### ANSWER SELECT t3.individual_last_name FROM organizations AS t1 JOIN organization_contact_individuals AS t2 ON t1.organization_id = t2.organization_id JOIN individuals AS t3 ON t2.individual_id = t3.individual_id WHERE t1.organization_name = "Labour Party" ORDER BY t2.date_contact_to DESC LIMIT 1</s>
{ "answer": "SELECT t3.individual_last_name FROM organizations AS t1 JOIN organization_contact_individuals AS t2 ON t1.organization_id = t2.organization_id JOIN individuals AS t3 ON t2.individual_id = t3.individual_id WHERE t1.organization_name = \"Labour Party\" ORDER BY t2.date_contact_to DESC LIMIT 1", "context": "CREATE TABLE organizations (organization_id VARCHAR, organization_name VARCHAR); CREATE TABLE individuals (individual_last_name VARCHAR, individual_id VARCHAR); CREATE TABLE organization_contact_individuals (organization_id VARCHAR, individual_id VARCHAR, date_contact_to VARCHAR)", "question": "Find the last name of the latest contact individual of the organization \"Labour Party\"." }
### QUESTION Find the last name of the first ever contact person of the organization with the highest UK Vat number. ### CONTEXT CREATE TABLE organizations (uk_vat_number INTEGER); CREATE TABLE individuals (individual_last_name VARCHAR, individual_id VARCHAR); CREATE TABLE organizations (organization_id VARCHAR, uk_vat_number INTEGER); CREATE TABLE organization_contact_individuals (organization_id VARCHAR, individual_id VARCHAR, date_contact_to VARCHAR) ### ANSWER SELECT t3.individual_last_name FROM organizations AS t1 JOIN organization_contact_individuals AS t2 ON t1.organization_id = t2.organization_id JOIN individuals AS t3 ON t2.individual_id = t3.individual_id WHERE t1.uk_vat_number = (SELECT MAX(uk_vat_number) FROM organizations) ORDER BY t2.date_contact_to LIMIT 1</s>
{ "answer": "SELECT t3.individual_last_name FROM organizations AS t1 JOIN organization_contact_individuals AS t2 ON t1.organization_id = t2.organization_id JOIN individuals AS t3 ON t2.individual_id = t3.individual_id WHERE t1.uk_vat_number = (SELECT MAX(uk_vat_number) FROM organizations) ORDER BY t2.date_contact_to LIMIT 1", "context": "CREATE TABLE organizations (uk_vat_number INTEGER); CREATE TABLE individuals (individual_last_name VARCHAR, individual_id VARCHAR); CREATE TABLE organizations (organization_id VARCHAR, uk_vat_number INTEGER); CREATE TABLE organization_contact_individuals (organization_id VARCHAR, individual_id VARCHAR, date_contact_to VARCHAR)", "question": "Find the last name of the first ever contact person of the organization with the highest UK Vat number." }
### QUESTION Find name of the services that has never been used. ### CONTEXT CREATE TABLE services (service_name VARCHAR); CREATE TABLE party_services (service_id VARCHAR); CREATE TABLE services (service_name VARCHAR, service_id VARCHAR) ### ANSWER SELECT service_name FROM services EXCEPT SELECT t1.service_name FROM services AS t1 JOIN party_services AS t2 ON t1.service_id = t2.service_id</s>
{ "answer": "SELECT service_name FROM services EXCEPT SELECT t1.service_name FROM services AS t1 JOIN party_services AS t2 ON t1.service_id = t2.service_id", "context": "CREATE TABLE services (service_name VARCHAR); CREATE TABLE party_services (service_id VARCHAR); CREATE TABLE services (service_name VARCHAR, service_id VARCHAR)", "question": "Find name of the services that has never been used." }
### QUESTION What was the total number of wins that had an against greater than 1136 but losses less than 15 with Ultima with less than 2 byes? ### CONTEXT CREATE TABLE table_name_62 (wins INTEGER, byes VARCHAR, golden_rivers VARCHAR, against VARCHAR, losses VARCHAR) ### ANSWER SELECT SUM(wins) FROM table_name_62 WHERE against > 1136 AND losses < 15 AND golden_rivers = "ultima" AND byes < 2</s>
{ "answer": "SELECT SUM(wins) FROM table_name_62 WHERE against > 1136 AND losses < 15 AND golden_rivers = \"ultima\" AND byes < 2", "context": "CREATE TABLE table_name_62 (wins INTEGER, byes VARCHAR, golden_rivers VARCHAR, against VARCHAR, losses VARCHAR)", "question": "What was the total number of wins that had an against greater than 1136 but losses less than 15 with Ultima with less than 2 byes?" }
### QUESTION Which is the email of the party that has used the services the most number of times? ### CONTEXT CREATE TABLE parties (party_email VARCHAR, party_id VARCHAR); CREATE TABLE party_services (customer_id VARCHAR) ### ANSWER SELECT t1.party_email FROM parties AS t1 JOIN party_services AS t2 ON t1.party_id = t2.customer_id GROUP BY t1.party_email ORDER BY COUNT(*) DESC LIMIT 1</s>
{ "answer": "SELECT t1.party_email FROM parties AS t1 JOIN party_services AS t2 ON t1.party_id = t2.customer_id GROUP BY t1.party_email ORDER BY COUNT(*) DESC LIMIT 1", "context": "CREATE TABLE parties (party_email VARCHAR, party_id VARCHAR); CREATE TABLE party_services (customer_id VARCHAR)", "question": "Which is the email of the party that has used the services the most number of times?" }
### QUESTION When middle assyrian empire is the ubaid period in mesopotamia what is the copper age? ### CONTEXT CREATE TABLE table_23537091_1 (copper_age VARCHAR, ubaid_period_in_mesopotamia VARCHAR) ### ANSWER SELECT copper_age FROM table_23537091_1 WHERE ubaid_period_in_mesopotamia = "Middle Assyrian Empire"</s>
{ "answer": "SELECT copper_age FROM table_23537091_1 WHERE ubaid_period_in_mesopotamia = \"Middle Assyrian Empire\"", "context": "CREATE TABLE table_23537091_1 (copper_age VARCHAR, ubaid_period_in_mesopotamia VARCHAR)", "question": "When middle assyrian empire is the ubaid period in mesopotamia what is the copper age?" }
### QUESTION When hittite old kingdom , minoan eruption is the ubaid period in mesopotamia what is the copper age? ### CONTEXT CREATE TABLE table_23537091_1 (copper_age VARCHAR, ubaid_period_in_mesopotamia VARCHAR) ### ANSWER SELECT copper_age FROM table_23537091_1 WHERE ubaid_period_in_mesopotamia = "Hittite Old Kingdom , Minoan eruption"</s>
{ "answer": "SELECT copper_age FROM table_23537091_1 WHERE ubaid_period_in_mesopotamia = \"Hittite Old Kingdom , Minoan eruption\"", "context": "CREATE TABLE table_23537091_1 (copper_age VARCHAR, ubaid_period_in_mesopotamia VARCHAR)", "question": "When hittite old kingdom , minoan eruption is the ubaid period in mesopotamia what is the copper age?" }
### QUESTION Find the last name of the individuals that have been contact individuals of an organization. ### CONTEXT CREATE TABLE individuals (individual_last_name VARCHAR, individual_id VARCHAR); CREATE TABLE organization_contact_individuals (individual_id VARCHAR) ### ANSWER SELECT DISTINCT t1.individual_last_name FROM individuals AS t1 JOIN organization_contact_individuals AS t2 ON t1.individual_id = t2.individual_id</s>
{ "answer": "SELECT DISTINCT t1.individual_last_name FROM individuals AS t1 JOIN organization_contact_individuals AS t2 ON t1.individual_id = t2.individual_id", "context": "CREATE TABLE individuals (individual_last_name VARCHAR, individual_id VARCHAR); CREATE TABLE organization_contact_individuals (individual_id VARCHAR)", "question": "Find the last name of the individuals that have been contact individuals of an organization." }
### QUESTION What is the name of organization that has the greatest number of contact individuals? ### CONTEXT CREATE TABLE organization_contact_individuals (organization_id VARCHAR); CREATE TABLE organizations (organization_name VARCHAR, organization_id VARCHAR) ### ANSWER SELECT t1.organization_name FROM organizations AS t1 JOIN organization_contact_individuals AS t2 ON t1.organization_id = t2.organization_id GROUP BY t1.organization_name ORDER BY COUNT(*) DESC LIMIT 1</s>
{ "answer": "SELECT t1.organization_name FROM organizations AS t1 JOIN organization_contact_individuals AS t2 ON t1.organization_id = t2.organization_id GROUP BY t1.organization_name ORDER BY COUNT(*) DESC LIMIT 1", "context": "CREATE TABLE organization_contact_individuals (organization_id VARCHAR); CREATE TABLE organizations (organization_name VARCHAR, organization_id VARCHAR)", "question": "What is the name of organization that has the greatest number of contact individuals?" }
### QUESTION When the second intermediate period of egypt is the ubaid period in mesopotamia how many early calcolithics are there? ### CONTEXT CREATE TABLE table_23537091_1 (early_chalcolithic VARCHAR, ubaid_period_in_mesopotamia VARCHAR) ### ANSWER SELECT COUNT(early_chalcolithic) FROM table_23537091_1 WHERE ubaid_period_in_mesopotamia = "Second Intermediate Period of Egypt"</s>
{ "answer": "SELECT COUNT(early_chalcolithic) FROM table_23537091_1 WHERE ubaid_period_in_mesopotamia = \"Second Intermediate Period of Egypt\"", "context": "CREATE TABLE table_23537091_1 (early_chalcolithic VARCHAR, ubaid_period_in_mesopotamia VARCHAR)", "question": "When the second intermediate period of egypt is the ubaid period in mesopotamia how many early calcolithics are there?" }
### QUESTION What is the area of the village with a census ranking of 1,442 of 5,008 and a population less than 1,778? ### CONTEXT CREATE TABLE table_name_92 (area_km_2 INTEGER, population VARCHAR, status VARCHAR, census_ranking VARCHAR) ### ANSWER SELECT MAX(area_km_2) FROM table_name_92 WHERE status = "village" AND census_ranking = "1,442 of 5,008" AND population < 1 OFFSET 778</s>
{ "answer": "SELECT MAX(area_km_2) FROM table_name_92 WHERE status = \"village\" AND census_ranking = \"1,442 of 5,008\" AND population < 1 OFFSET 778", "context": "CREATE TABLE table_name_92 (area_km_2 INTEGER, population VARCHAR, status VARCHAR, census_ranking VARCHAR)", "question": "What is the area of the village with a census ranking of 1,442 of 5,008 and a population less than 1,778?" }
### QUESTION When david o'doherty and katherine parkinson are both on the davids team when is the first broadcast? ### CONTEXT CREATE TABLE table_23575917_6 (first_broadcast VARCHAR, davids_team VARCHAR) ### ANSWER SELECT first_broadcast FROM table_23575917_6 WHERE davids_team = "David O'Doherty and Katherine Parkinson"</s>
{ "answer": "SELECT first_broadcast FROM table_23575917_6 WHERE davids_team = \"David O'Doherty and Katherine Parkinson\"", "context": "CREATE TABLE table_23575917_6 (first_broadcast VARCHAR, davids_team VARCHAR)", "question": "When david o'doherty and katherine parkinson are both on the davids team when is the first broadcast?" }
### QUESTION Show the school name and driver name for all school buses. ### CONTEXT CREATE TABLE school (school VARCHAR, school_id VARCHAR); CREATE TABLE school_bus (school_id VARCHAR, driver_id VARCHAR); CREATE TABLE driver (name VARCHAR, driver_id VARCHAR) ### ANSWER SELECT T2.school, T3.name FROM school_bus AS T1 JOIN school AS T2 ON T1.school_id = T2.school_id JOIN driver AS T3 ON T1.driver_id = T3.driver_id</s>
{ "answer": "SELECT T2.school, T3.name FROM school_bus AS T1 JOIN school AS T2 ON T1.school_id = T2.school_id JOIN driver AS T3 ON T1.driver_id = T3.driver_id", "context": "CREATE TABLE school (school VARCHAR, school_id VARCHAR); CREATE TABLE school_bus (school_id VARCHAR, driver_id VARCHAR); CREATE TABLE driver (name VARCHAR, driver_id VARCHAR)", "question": "Show the school name and driver name for all school buses." }
### QUESTION How many shows did team David consist of vernon kay and dara Γ³ briain ### CONTEXT CREATE TABLE table_23575917_8 (episode VARCHAR, davids_team VARCHAR) ### ANSWER SELECT COUNT(episode) FROM table_23575917_8 WHERE davids_team = "Vernon Kay and Dara Γ“ Briain"</s>
{ "answer": "SELECT COUNT(episode) FROM table_23575917_8 WHERE davids_team = \"Vernon Kay and Dara Γ“ Briain\"", "context": "CREATE TABLE table_23575917_8 (episode VARCHAR, davids_team VARCHAR)", "question": "How many shows did team David consist of vernon kay and dara Γ³ briain" }
### QUESTION Show the type of school and the number of buses for each type. ### CONTEXT CREATE TABLE school (type VARCHAR, school_id VARCHAR); CREATE TABLE school_bus (school_id VARCHAR) ### ANSWER SELECT T2.type, COUNT(*) FROM school_bus AS T1 JOIN school AS T2 ON T1.school_id = T2.school_id GROUP BY T2.type</s>
{ "answer": "SELECT T2.type, COUNT(*) FROM school_bus AS T1 JOIN school AS T2 ON T1.school_id = T2.school_id GROUP BY T2.type", "context": "CREATE TABLE school (type VARCHAR, school_id VARCHAR); CREATE TABLE school_bus (school_id VARCHAR)", "question": "Show the type of school and the number of buses for each type." }
### QUESTION How many different horse-powers does the Cochrane have? ### CONTEXT CREATE TABLE table_23614702_1 (horse__power VARCHAR, warship VARCHAR) ### ANSWER SELECT COUNT(horse__power) FROM table_23614702_1 WHERE warship = "Cochrane"</s>
{ "answer": "SELECT COUNT(horse__power) FROM table_23614702_1 WHERE warship = \"Cochrane\"", "context": "CREATE TABLE table_23614702_1 (horse__power VARCHAR, warship VARCHAR)", "question": "How many different horse-powers does the Cochrane have?" }
### QUESTION What are the names and types of the companies that have ever operated a flight? ### CONTEXT CREATE TABLE operate_company (name VARCHAR, type VARCHAR, id VARCHAR); CREATE TABLE flight (Id VARCHAR) ### ANSWER SELECT T1.name, T1.type FROM operate_company AS T1 JOIN flight AS t2 ON T1.id = T2.company_id</s>
{ "answer": "SELECT T1.name, T1.type FROM operate_company AS T1 JOIN flight AS t2 ON T1.id = T2.company_id", "context": "CREATE TABLE operate_company (name VARCHAR, type VARCHAR, id VARCHAR); CREATE TABLE flight (Id VARCHAR)", "question": "What are the names and types of the companies that have ever operated a flight?" }
### QUESTION What is the id, name and IATA code of the airport that had most number of flights? ### CONTEXT CREATE TABLE airport (id VARCHAR, name VARCHAR, IATA VARCHAR); CREATE TABLE flight (id VARCHAR, airport_id VARCHAR) ### ANSWER SELECT T1.id, T1.name, T1.IATA FROM airport AS T1 JOIN flight AS T2 ON T1.id = T2.airport_id GROUP BY T2.id ORDER BY COUNT(*) DESC LIMIT 1</s>
{ "answer": "SELECT T1.id, T1.name, T1.IATA FROM airport AS T1 JOIN flight AS T2 ON T1.id = T2.airport_id GROUP BY T2.id ORDER BY COUNT(*) DESC LIMIT 1", "context": "CREATE TABLE airport (id VARCHAR, name VARCHAR, IATA VARCHAR); CREATE TABLE flight (id VARCHAR, airport_id VARCHAR)", "question": "What is the id, name and IATA code of the airport that had most number of flights?" }
### QUESTION What are the different pilot names who had piloted a flight in the country 'United States' or in the airport named 'Billund Airport'? ### CONTEXT CREATE TABLE airport (id VARCHAR, country VARCHAR, name VARCHAR); CREATE TABLE flight (pilot VARCHAR, airport_id VARCHAR) ### ANSWER SELECT DISTINCT T2.pilot FROM airport AS T1 JOIN flight AS T2 ON T1.id = T2.airport_id WHERE T1.country = 'United States' OR T1.name = 'Billund Airport'</s>
{ "answer": "SELECT DISTINCT T2.pilot FROM airport AS T1 JOIN flight AS T2 ON T1.id = T2.airport_id WHERE T1.country = 'United States' OR T1.name = 'Billund Airport'", "context": "CREATE TABLE airport (id VARCHAR, country VARCHAR, name VARCHAR); CREATE TABLE flight (pilot VARCHAR, airport_id VARCHAR)", "question": "What are the different pilot names who had piloted a flight in the country 'United States' or in the airport named 'Billund Airport'?" }
### QUESTION What is the primary artillery for the 1,051 ships? ### CONTEXT CREATE TABLE table_23614702_2 (main_artillery VARCHAR, tons___lton__ VARCHAR) ### ANSWER SELECT main_artillery FROM table_23614702_2 WHERE tons___lton__ = "1,051"</s>
{ "answer": "SELECT main_artillery FROM table_23614702_2 WHERE tons___lton__ = \"1,051\"", "context": "CREATE TABLE table_23614702_2 (main_artillery VARCHAR, tons___lton__ VARCHAR)", "question": "What is the primary artillery for the 1,051 ships?" }
### QUESTION List the name of the pilots who have flied for both a company that mainly provide 'Cargo' services and a company that runs 'Catering services' activities. ### CONTEXT CREATE TABLE operate_company (id VARCHAR, principal_activities VARCHAR); CREATE TABLE flight (Id VARCHAR) ### ANSWER SELECT T2.pilot FROM operate_company AS T1 JOIN flight AS t2 ON T1.id = T2.company_id WHERE T1.principal_activities = 'Cargo' INTERSECT SELECT T2.pilot FROM operate_company AS T1 JOIN flight AS t2 ON T1.id = T2.company_id WHERE T1.principal_activities = 'Catering services'</s>
{ "answer": "SELECT T2.pilot FROM operate_company AS T1 JOIN flight AS t2 ON T1.id = T2.company_id WHERE T1.principal_activities = 'Cargo' INTERSECT SELECT T2.pilot FROM operate_company AS T1 JOIN flight AS t2 ON T1.id = T2.company_id WHERE T1.principal_activities = 'Catering services'", "context": "CREATE TABLE operate_company (id VARCHAR, principal_activities VARCHAR); CREATE TABLE flight (Id VARCHAR)", "question": "List the name of the pilots who have flied for both a company that mainly provide 'Cargo' services and a company that runs 'Catering services' activities." }
### QUESTION How many companies operates airlines in each airport? ### CONTEXT CREATE TABLE airport (id VARCHAR); CREATE TABLE flight (Id VARCHAR); CREATE TABLE operate_company (id VARCHAR) ### ANSWER SELECT T3.id, COUNT(*) FROM operate_company AS T1 JOIN flight AS t2 ON T1.id = T2.company_id JOIN airport AS T3 ON T2.airport_id = T3.id GROUP BY T3.id</s>
{ "answer": "SELECT T3.id, COUNT(*) FROM operate_company AS T1 JOIN flight AS t2 ON T1.id = T2.company_id JOIN airport AS T3 ON T2.airport_id = T3.id GROUP BY T3.id", "context": "CREATE TABLE airport (id VARCHAR); CREATE TABLE flight (Id VARCHAR); CREATE TABLE operate_company (id VARCHAR)", "question": "How many companies operates airlines in each airport?" }
### QUESTION Which player had a draft before 1975 and before round 6? ### CONTEXT CREATE TABLE table_name_79 (player VARCHAR, draft VARCHAR, round VARCHAR) ### ANSWER SELECT player FROM table_name_79 WHERE draft < 1975 AND round < 6</s>
{ "answer": "SELECT player FROM table_name_79 WHERE draft < 1975 AND round < 6", "context": "CREATE TABLE table_name_79 (player VARCHAR, draft VARCHAR, round VARCHAR)", "question": "Which player had a draft before 1975 and before round 6?" }
### QUESTION Show statement id, statement detail, account detail for accounts. ### CONTEXT CREATE TABLE Accounts (statement_id VARCHAR, account_details VARCHAR); CREATE TABLE Statements (statement_details VARCHAR, statement_id VARCHAR) ### ANSWER SELECT T1.statement_id, T2.statement_details, T1.account_details FROM Accounts AS T1 JOIN Statements AS T2 ON T1.statement_id = T2.statement_id</s>
{ "answer": "SELECT T1.statement_id, T2.statement_details, T1.account_details FROM Accounts AS T1 JOIN Statements AS T2 ON T1.statement_id = T2.statement_id", "context": "CREATE TABLE Accounts (statement_id VARCHAR, account_details VARCHAR); CREATE TABLE Statements (statement_details VARCHAR, statement_id VARCHAR)", "question": "Show statement id, statement detail, account detail for accounts." }
### QUESTION Show the statement id and the statement detail for the statement with most number of accounts. ### CONTEXT CREATE TABLE Accounts (statement_id VARCHAR); CREATE TABLE Statements (statement_details VARCHAR, statement_id VARCHAR) ### ANSWER SELECT T1.statement_id, T2.statement_details FROM Accounts AS T1 JOIN Statements AS T2 ON T1.statement_id = T2.statement_id GROUP BY T1.statement_id ORDER BY COUNT(*) DESC LIMIT 1</s>
{ "answer": "SELECT T1.statement_id, T2.statement_details FROM Accounts AS T1 JOIN Statements AS T2 ON T1.statement_id = T2.statement_id GROUP BY T1.statement_id ORDER BY COUNT(*) DESC LIMIT 1", "context": "CREATE TABLE Accounts (statement_id VARCHAR); CREATE TABLE Statements (statement_details VARCHAR, statement_id VARCHAR)", "question": "Show the statement id and the statement detail for the statement with most number of accounts." }
### QUESTION List the document type code, document name, and document description for the document with name 'Noel CV' or name 'King Book'. ### CONTEXT CREATE TABLE Documents (document_type_code VARCHAR, document_name VARCHAR, document_description VARCHAR) ### ANSWER SELECT document_type_code, document_name, document_description FROM Documents WHERE document_name = 'Noel CV' OR document_name = 'King Book'</s>
{ "answer": "SELECT document_type_code, document_name, document_description FROM Documents WHERE document_name = 'Noel CV' OR document_name = 'King Book'", "context": "CREATE TABLE Documents (document_type_code VARCHAR, document_name VARCHAR, document_description VARCHAR)", "question": "List the document type code, document name, and document description for the document with name 'Noel CV' or name 'King Book'." }
### QUESTION Show the document name and the document date for all documents on project with details 'Graph Database project'. ### CONTEXT CREATE TABLE Documents (project_id VARCHAR); CREATE TABLE projects (project_id VARCHAR, project_details VARCHAR) ### ANSWER SELECT document_name, document_date FROM Documents AS T1 JOIN projects AS T2 ON T1.project_id = T2.project_id WHERE T2.project_details = 'Graph Database project'</s>
{ "answer": "SELECT document_name, document_date FROM Documents AS T1 JOIN projects AS T2 ON T1.project_id = T2.project_id WHERE T2.project_details = 'Graph Database project'", "context": "CREATE TABLE Documents (project_id VARCHAR); CREATE TABLE projects (project_id VARCHAR, project_details VARCHAR)", "question": "Show the document name and the document date for all documents on project with details 'Graph Database project'." }
### QUESTION What's the percentage of all immigrants in 2007 in the country with 1.7% of all immigrants in 2008? ### CONTEXT CREATE TABLE table_23619212_1 (_percentage_of_all_immigrants_2007 VARCHAR, _percentage_of_all_immigrants_2008 VARCHAR) ### ANSWER SELECT _percentage_of_all_immigrants_2007 FROM table_23619212_1 WHERE _percentage_of_all_immigrants_2008 = "1.7%"</s>
{ "answer": "SELECT _percentage_of_all_immigrants_2007 FROM table_23619212_1 WHERE _percentage_of_all_immigrants_2008 = \"1.7%\"", "context": "CREATE TABLE table_23619212_1 (_percentage_of_all_immigrants_2007 VARCHAR, _percentage_of_all_immigrants_2008 VARCHAR)", "question": "What's the percentage of all immigrants in 2007 in the country with 1.7% of all immigrants in 2008?" }
### QUESTION What is the id of the project with least number of documents? ### CONTEXT CREATE TABLE Documents (project_id VARCHAR) ### ANSWER SELECT project_id FROM Documents GROUP BY project_id ORDER BY COUNT(*) LIMIT 1</s>
{ "answer": "SELECT project_id FROM Documents GROUP BY project_id ORDER BY COUNT(*) LIMIT 1", "context": "CREATE TABLE Documents (project_id VARCHAR)", "question": "What is the id of the project with least number of documents?" }
### QUESTION How many different percentages of immigrants in 2006 can there be for Morocco? ### CONTEXT CREATE TABLE table_23619212_1 (_percentage_of_all_immigrants_2006 VARCHAR, country VARCHAR) ### ANSWER SELECT COUNT(_percentage_of_all_immigrants_2006) FROM table_23619212_1 WHERE country = "Morocco"</s>
{ "answer": "SELECT COUNT(_percentage_of_all_immigrants_2006) FROM table_23619212_1 WHERE country = \"Morocco\"", "context": "CREATE TABLE table_23619212_1 (_percentage_of_all_immigrants_2006 VARCHAR, country VARCHAR)", "question": "How many different percentages of immigrants in 2006 can there be for Morocco?" }
### QUESTION How many different percentages of immigrants are there for the year of 2007 in the countries with 1.2% of the immigrants in the year of 2005? ### CONTEXT CREATE TABLE table_23619212_1 (_percentage_of_all_immigrants_2007 VARCHAR, _percentage_of_all_immigrants_2005 VARCHAR) ### ANSWER SELECT COUNT(_percentage_of_all_immigrants_2007) FROM table_23619212_1 WHERE _percentage_of_all_immigrants_2005 = "1.2%"</s>
{ "answer": "SELECT COUNT(_percentage_of_all_immigrants_2007) FROM table_23619212_1 WHERE _percentage_of_all_immigrants_2005 = \"1.2%\"", "context": "CREATE TABLE table_23619212_1 (_percentage_of_all_immigrants_2007 VARCHAR, _percentage_of_all_immigrants_2005 VARCHAR)", "question": "How many different percentages of immigrants are there for the year of 2007 in the countries with 1.2% of the immigrants in the year of 2005?" }
### QUESTION What is the total of Losses with a Result of runner-up, Wins of 1, and a Year smaller than 2006? ### CONTEXT CREATE TABLE table_name_50 (losses INTEGER, year VARCHAR, result VARCHAR, wins VARCHAR) ### ANSWER SELECT SUM(losses) FROM table_name_50 WHERE result = "runner-up" AND wins = 1 AND year < 2006</s>
{ "answer": "SELECT SUM(losses) FROM table_name_50 WHERE result = \"runner-up\" AND wins = 1 AND year < 2006", "context": "CREATE TABLE table_name_50 (losses INTEGER, year VARCHAR, result VARCHAR, wins VARCHAR)", "question": "What is the total of Losses with a Result of runner-up, Wins of 1, and a Year smaller than 2006?" }
### QUESTION Who were the opponents in the final where the score was 6–4, 2–6, 6–4, 7–6(3)? ### CONTEXT CREATE TABLE table_2362486_1 (opponents_in_the_final VARCHAR, score_in_the_final VARCHAR) ### ANSWER SELECT opponents_in_the_final FROM table_2362486_1 WHERE score_in_the_final = "6–4, 2–6, 6–4, 7–6(3)"</s>
{ "answer": "SELECT opponents_in_the_final FROM table_2362486_1 WHERE score_in_the_final = \"6–4, 2–6, 6–4, 7–6(3)\"", "context": "CREATE TABLE table_2362486_1 (opponents_in_the_final VARCHAR, score_in_the_final VARCHAR)", "question": "Who were the opponents in the final where the score was 6–4, 2–6, 6–4, 7–6(3)?" }
### QUESTION Show the statement detail and the corresponding document name for the statement with detail 'Private Project'. ### CONTEXT CREATE TABLE Statements (statement_details VARCHAR, statement_id VARCHAR); CREATE TABLE Documents (document_name VARCHAR, document_id VARCHAR) ### ANSWER SELECT T1.statement_details, T2.document_name FROM Statements AS T1 JOIN Documents AS T2 ON T1.statement_id = T2.document_id WHERE T1.statement_details = 'Private Project'</s>
{ "answer": "SELECT T1.statement_details, T2.document_name FROM Statements AS T1 JOIN Documents AS T2 ON T1.statement_id = T2.document_id WHERE T1.statement_details = 'Private Project'", "context": "CREATE TABLE Statements (statement_details VARCHAR, statement_id VARCHAR); CREATE TABLE Documents (document_name VARCHAR, document_id VARCHAR)", "question": "Show the statement detail and the corresponding document name for the statement with detail 'Private Project'." }
### QUESTION What is the document type name and the document type description and creation date for all the documents? ### CONTEXT CREATE TABLE Ref_document_types (document_type_name VARCHAR, document_type_description VARCHAR, document_type_code VARCHAR); CREATE TABLE Documents (Document_date VARCHAR, document_type_code VARCHAR) ### ANSWER SELECT T1.document_type_name, T1.document_type_description, T2.Document_date FROM Ref_document_types AS T1 JOIN Documents AS T2 ON T1.document_type_code = T2.document_type_code</s>
{ "answer": "SELECT T1.document_type_name, T1.document_type_description, T2.Document_date FROM Ref_document_types AS T1 JOIN Documents AS T2 ON T1.document_type_code = T2.document_type_code", "context": "CREATE TABLE Ref_document_types (document_type_name VARCHAR, document_type_description VARCHAR, document_type_code VARCHAR); CREATE TABLE Documents (Document_date VARCHAR, document_type_code VARCHAR)", "question": "What is the document type name and the document type description and creation date for all the documents?" }
### QUESTION Name the total number of african record ### CONTEXT CREATE TABLE table_23619492_3 (paula_radcliffe___gbr__ VARCHAR, world_record VARCHAR) ### ANSWER SELECT COUNT(paula_radcliffe___gbr__) FROM table_23619492_3 WHERE world_record = "African record"</s>
{ "answer": "SELECT COUNT(paula_radcliffe___gbr__) FROM table_23619492_3 WHERE world_record = \"African record\"", "context": "CREATE TABLE table_23619492_3 (paula_radcliffe___gbr__ VARCHAR, world_record VARCHAR)", "question": "Name the total number of african record" }
### QUESTION What is the greatest Wins with Matches smaller than 5, and a Year of 1994? ### CONTEXT CREATE TABLE table_name_26 (wins INTEGER, matches VARCHAR, year VARCHAR) ### ANSWER SELECT MAX(wins) FROM table_name_26 WHERE matches < 5 AND year = 1994</s>
{ "answer": "SELECT MAX(wins) FROM table_name_26 WHERE matches < 5 AND year = 1994", "context": "CREATE TABLE table_name_26 (wins INTEGER, matches VARCHAR, year VARCHAR)", "question": "What is the greatest Wins with Matches smaller than 5, and a Year of 1994?" }
### QUESTION What is the project id and detail for the project with at least two documents? ### CONTEXT CREATE TABLE Projects (project_id VARCHAR, project_details VARCHAR); CREATE TABLE Documents (project_id VARCHAR) ### ANSWER SELECT T1.project_id, T1.project_details FROM Projects AS T1 JOIN Documents AS T2 ON T1.project_id = T2.project_id GROUP BY T1.project_id HAVING COUNT(*) > 2</s>
{ "answer": "SELECT T1.project_id, T1.project_details FROM Projects AS T1 JOIN Documents AS T2 ON T1.project_id = T2.project_id GROUP BY T1.project_id HAVING COUNT(*) > 2", "context": "CREATE TABLE Projects (project_id VARCHAR, project_details VARCHAR); CREATE TABLE Documents (project_id VARCHAR)", "question": "What is the project id and detail for the project with at least two documents?" }
### QUESTION What is the total number of Year with Wins of 1, and Losses smaller than 1? ### CONTEXT CREATE TABLE table_name_93 (year INTEGER, wins VARCHAR, losses VARCHAR) ### ANSWER SELECT SUM(year) FROM table_name_93 WHERE wins = 1 AND losses < 1</s>
{ "answer": "SELECT SUM(year) FROM table_name_93 WHERE wins = 1 AND losses < 1", "context": "CREATE TABLE table_name_93 (year INTEGER, wins VARCHAR, losses VARCHAR)", "question": "What is the total number of Year with Wins of 1, and Losses smaller than 1?" }
### QUESTION What is the project detail for the project with document "King Book"? ### CONTEXT CREATE TABLE Projects (project_details VARCHAR, project_id VARCHAR); CREATE TABLE Documents (project_id VARCHAR, document_name VARCHAR) ### ANSWER SELECT T1.project_details FROM Projects AS T1 JOIN Documents AS T2 ON T1.project_id = T2.project_id WHERE T2.document_name = "King Book"</s>
{ "answer": "SELECT T1.project_details FROM Projects AS T1 JOIN Documents AS T2 ON T1.project_id = T2.project_id WHERE T2.document_name = \"King Book\"", "context": "CREATE TABLE Projects (project_details VARCHAR, project_id VARCHAR); CREATE TABLE Documents (project_id VARCHAR, document_name VARCHAR)", "question": "What is the project detail for the project with document \"King Book\"?" }
### QUESTION How many season had Melgar as a champion? ### CONTEXT CREATE TABLE table_23647668_2 (season VARCHAR, champion VARCHAR) ### ANSWER SELECT COUNT(season) FROM table_23647668_2 WHERE champion = "Melgar"</s>
{ "answer": "SELECT COUNT(season) FROM table_23647668_2 WHERE champion = \"Melgar\"", "context": "CREATE TABLE table_23647668_2 (season VARCHAR, champion VARCHAR)", "question": "How many season had Melgar as a champion?" }
### QUESTION What is the description for the budget type with code ORG? ### CONTEXT CREATE TABLE Ref_budget_codes (budget_type_description VARCHAR, budget_type_code VARCHAR) ### ANSWER SELECT budget_type_description FROM Ref_budget_codes WHERE budget_type_code = "ORG"</s>
{ "answer": "SELECT budget_type_description FROM Ref_budget_codes WHERE budget_type_code = \"ORG\"", "context": "CREATE TABLE Ref_budget_codes (budget_type_description VARCHAR, budget_type_code VARCHAR)", "question": "What is the description for the budget type with code ORG?" }
### QUESTION When the venue is away and the opponents are the bracknell bees, what is the competition? ### CONTEXT CREATE TABLE table_name_88 (competition VARCHAR, venue VARCHAR, opponent VARCHAR) ### ANSWER SELECT competition FROM table_name_88 WHERE venue = "away" AND opponent = "bracknell bees"</s>
{ "answer": "SELECT competition FROM table_name_88 WHERE venue = \"away\" AND opponent = \"bracknell bees\"", "context": "CREATE TABLE table_name_88 (competition VARCHAR, venue VARCHAR, opponent VARCHAR)", "question": "When the venue is away and the opponents are the bracknell bees, what is the competition?" }
### QUESTION Show the budget type code and description and the corresponding document id. ### CONTEXT CREATE TABLE Ref_budget_codes (budget_type_code VARCHAR, budget_type_description VARCHAR); CREATE TABLE Documents_with_expenses (document_id VARCHAR, budget_type_code VARCHAR) ### ANSWER SELECT T2.budget_type_code, T2.budget_type_description, T1.document_id FROM Documents_with_expenses AS T1 JOIN Ref_budget_codes AS T2 ON T1.budget_type_code = T2.budget_type_code</s>
{ "answer": "SELECT T2.budget_type_code, T2.budget_type_description, T1.document_id FROM Documents_with_expenses AS T1 JOIN Ref_budget_codes AS T2 ON T1.budget_type_code = T2.budget_type_code", "context": "CREATE TABLE Ref_budget_codes (budget_type_code VARCHAR, budget_type_description VARCHAR); CREATE TABLE Documents_with_expenses (document_id VARCHAR, budget_type_code VARCHAR)", "question": "Show the budget type code and description and the corresponding document id." }
### QUESTION Show ids for all documents with budget types described as 'Government'. ### CONTEXT CREATE TABLE Documents_with_expenses (document_id VARCHAR, Budget_Type_code VARCHAR); CREATE TABLE Ref_Budget_Codes (Budget_Type_code VARCHAR, budget_type_Description VARCHAR) ### ANSWER SELECT T1.document_id FROM Documents_with_expenses AS T1 JOIN Ref_Budget_Codes AS T2 ON T1.Budget_Type_code = T2.Budget_Type_code WHERE T2.budget_type_Description = "Government"</s>
{ "answer": "SELECT T1.document_id FROM Documents_with_expenses AS T1 JOIN Ref_Budget_Codes AS T2 ON T1.Budget_Type_code = T2.Budget_Type_code WHERE T2.budget_type_Description = \"Government\"", "context": "CREATE TABLE Documents_with_expenses (document_id VARCHAR, Budget_Type_code VARCHAR); CREATE TABLE Ref_Budget_Codes (Budget_Type_code VARCHAR, budget_type_Description VARCHAR)", "question": "Show ids for all documents with budget types described as 'Government'." }
### QUESTION Show ids for all documents in type CV without expense budgets. ### CONTEXT CREATE TABLE Documents_with_expenses (document_id VARCHAR, document_type_code VARCHAR); CREATE TABLE Documents (document_id VARCHAR, document_type_code VARCHAR) ### ANSWER SELECT document_id FROM Documents WHERE document_type_code = "CV" EXCEPT SELECT document_id FROM Documents_with_expenses</s>
{ "answer": "SELECT document_id FROM Documents WHERE document_type_code = \"CV\" EXCEPT SELECT document_id FROM Documents_with_expenses", "context": "CREATE TABLE Documents_with_expenses (document_id VARCHAR, document_type_code VARCHAR); CREATE TABLE Documents (document_id VARCHAR, document_type_code VARCHAR)", "question": "Show ids for all documents in type CV without expense budgets." }
### QUESTION What are the ids of documents with letter 's' in the name with any expense budgets. ### CONTEXT CREATE TABLE Documents_with_expenses (document_id VARCHAR); CREATE TABLE Documents (document_id VARCHAR, document_name VARCHAR) ### ANSWER SELECT T1.document_id FROM Documents AS T1 JOIN Documents_with_expenses AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name LIKE '%s%'</s>
{ "answer": "SELECT T1.document_id FROM Documents AS T1 JOIN Documents_with_expenses AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name LIKE '%s%'", "context": "CREATE TABLE Documents_with_expenses (document_id VARCHAR); CREATE TABLE Documents (document_id VARCHAR, document_name VARCHAR)", "question": "What are the ids of documents with letter 's' in the name with any expense budgets." }
### QUESTION What race was a round smaller than 8, on 6 july? ### CONTEXT CREATE TABLE table_name_45 (race VARCHAR, round VARCHAR, date VARCHAR) ### ANSWER SELECT race FROM table_name_45 WHERE round < 8 AND date = "6 july"</s>
{ "answer": "SELECT race FROM table_name_45 WHERE round < 8 AND date = \"6 july\"", "context": "CREATE TABLE table_name_45 (race VARCHAR, round VARCHAR, date VARCHAR)", "question": "What race was a round smaller than 8, on 6 july?" }
### QUESTION What are the dates for the documents with both 'GV' type and 'SF' type expenses? ### CONTEXT CREATE TABLE Documents_with_Expenses (document_id VARCHAR, budget_type_code VARCHAR); CREATE TABLE Documents (document_date VARCHAR, document_id VARCHAR) ### ANSWER SELECT T1.document_date FROM Documents AS T1 JOIN Documents_with_Expenses AS T2 ON T1.document_id = T2.document_id WHERE T2.budget_type_code = 'GV' INTERSECT SELECT T1.document_date FROM Documents AS T1 JOIN Documents_with_Expenses AS T2 ON T1.document_id = T2.document_id WHERE T2.budget_type_code = 'SF'</s>
{ "answer": "SELECT T1.document_date FROM Documents AS T1 JOIN Documents_with_Expenses AS T2 ON T1.document_id = T2.document_id WHERE T2.budget_type_code = 'GV' INTERSECT SELECT T1.document_date FROM Documents AS T1 JOIN Documents_with_Expenses AS T2 ON T1.document_id = T2.document_id WHERE T2.budget_type_code = 'SF'", "context": "CREATE TABLE Documents_with_Expenses (document_id VARCHAR, budget_type_code VARCHAR); CREATE TABLE Documents (document_date VARCHAR, document_id VARCHAR)", "question": "What are the dates for the documents with both 'GV' type and 'SF' type expenses?" }
### QUESTION What week were there 56,023 people in attendance? ### CONTEXT CREATE TABLE table_name_29 (week VARCHAR, attendance VARCHAR) ### ANSWER SELECT COUNT(week) FROM table_name_29 WHERE attendance = 56 OFFSET 023</s>
{ "answer": "SELECT COUNT(week) FROM table_name_29 WHERE attendance = 56 OFFSET 023", "context": "CREATE TABLE table_name_29 (week VARCHAR, attendance VARCHAR)", "question": "What week were there 56,023 people in attendance?" }
### QUESTION What is the attendance number later than week 9 on November 20, 1983? ### CONTEXT CREATE TABLE table_name_45 (attendance VARCHAR, week VARCHAR, date VARCHAR) ### ANSWER SELECT COUNT(attendance) FROM table_name_45 WHERE week > 9 AND date = "november 20, 1983"</s>
{ "answer": "SELECT COUNT(attendance) FROM table_name_45 WHERE week > 9 AND date = \"november 20, 1983\"", "context": "CREATE TABLE table_name_45 (attendance VARCHAR, week VARCHAR, date VARCHAR)", "question": "What is the attendance number later than week 9 on November 20, 1983?" }
### QUESTION What is Score in The Final, when Opponent in The Final is "John McEnroe", and when Championship is "Los Angeles , U.S."? ### CONTEXT CREATE TABLE table_name_98 (score_in_the_final VARCHAR, opponent_in_the_final VARCHAR, championship VARCHAR) ### ANSWER SELECT score_in_the_final FROM table_name_98 WHERE opponent_in_the_final = "john mcenroe" AND championship = "los angeles , u.s."</s>
{ "answer": "SELECT score_in_the_final FROM table_name_98 WHERE opponent_in_the_final = \"john mcenroe\" AND championship = \"los angeles , u.s.\"", "context": "CREATE TABLE table_name_98 (score_in_the_final VARCHAR, opponent_in_the_final VARCHAR, championship VARCHAR)", "question": "What is Score in The Final, when Opponent in The Final is \"John McEnroe\", and when Championship is \"Los Angeles , U.S.\"?" }
### QUESTION What album was the song It's going so badly on? ### CONTEXT CREATE TABLE table_23667534_1 (album_s_ VARCHAR, song_s__title VARCHAR) ### ANSWER SELECT album_s_ FROM table_23667534_1 WHERE song_s__title = "It's Going So Badly"</s>
{ "answer": "SELECT album_s_ FROM table_23667534_1 WHERE song_s__title = \"It's Going So Badly\"", "context": "CREATE TABLE table_23667534_1 (album_s_ VARCHAR, song_s__title VARCHAR)", "question": "What album was the song It's going so badly on?" }
### QUESTION List the name of all projects that are operated longer than the average working hours of all projects. ### CONTEXT CREATE TABLE projects (name VARCHAR, hours INTEGER) ### ANSWER SELECT name FROM projects WHERE hours > (SELECT AVG(hours) FROM projects)</s>
{ "answer": "SELECT name FROM projects WHERE hours > (SELECT AVG(hours) FROM projects)", "context": "CREATE TABLE projects (name VARCHAR, hours INTEGER)", "question": "List the name of all projects that are operated longer than the average working hours of all projects." }
### QUESTION Which Country has a Place of t10, and a Player of tony jacklin? ### CONTEXT CREATE TABLE table_name_2 (country VARCHAR, place VARCHAR, player VARCHAR) ### ANSWER SELECT country FROM table_name_2 WHERE place = "t10" AND player = "tony jacklin"</s>
{ "answer": "SELECT country FROM table_name_2 WHERE place = \"t10\" AND player = \"tony jacklin\"", "context": "CREATE TABLE table_name_2 (country VARCHAR, place VARCHAR, player VARCHAR)", "question": "Which Country has a Place of t10, and a Player of tony jacklin?" }
### QUESTION Find the name of the project for which a scientist whose name contains β€˜Smith’ is assigned to. ### CONTEXT CREATE TABLE scientists (SSN VARCHAR, name VARCHAR); CREATE TABLE assignedto (project VARCHAR, scientist VARCHAR); CREATE TABLE projects (name VARCHAR, code VARCHAR) ### ANSWER SELECT T2.name FROM assignedto AS T1 JOIN projects AS T2 ON T1.project = T2.code JOIN scientists AS T3 ON T1.scientist = T3.SSN WHERE T3.name LIKE '%Smith%'</s>
{ "answer": "SELECT T2.name FROM assignedto AS T1 JOIN projects AS T2 ON T1.project = T2.code JOIN scientists AS T3 ON T1.scientist = T3.SSN WHERE T3.name LIKE '%Smith%'", "context": "CREATE TABLE scientists (SSN VARCHAR, name VARCHAR); CREATE TABLE assignedto (project VARCHAR, scientist VARCHAR); CREATE TABLE projects (name VARCHAR, code VARCHAR)", "question": "Find the name of the project for which a scientist whose name contains β€˜Smith’ is assigned to." }
### QUESTION Find the total hours of the projects that scientists named Michael Rogers or Carol Smith are assigned to. ### CONTEXT CREATE TABLE scientists (SSN VARCHAR, name VARCHAR); CREATE TABLE projects (hours INTEGER, code VARCHAR); CREATE TABLE assignedto (project VARCHAR, scientist VARCHAR) ### ANSWER SELECT SUM(T2.hours) FROM assignedto AS T1 JOIN projects AS T2 ON T1.project = T2.code JOIN scientists AS T3 ON T1.scientist = T3.SSN WHERE T3.name = 'Michael Rogers' OR T3.name = 'Carol Smith'</s>
{ "answer": "SELECT SUM(T2.hours) FROM assignedto AS T1 JOIN projects AS T2 ON T1.project = T2.code JOIN scientists AS T3 ON T1.scientist = T3.SSN WHERE T3.name = 'Michael Rogers' OR T3.name = 'Carol Smith'", "context": "CREATE TABLE scientists (SSN VARCHAR, name VARCHAR); CREATE TABLE projects (hours INTEGER, code VARCHAR); CREATE TABLE assignedto (project VARCHAR, scientist VARCHAR)", "question": "Find the total hours of the projects that scientists named Michael Rogers or Carol Smith are assigned to." }
### QUESTION Find the name of the scientist who worked on both a project named 'Matter of Time' and a project named 'A Puzzling Parallax'. ### CONTEXT CREATE TABLE projects (code VARCHAR, name VARCHAR); CREATE TABLE scientists (name VARCHAR, SSN VARCHAR); CREATE TABLE assignedto (project VARCHAR, scientist VARCHAR) ### ANSWER SELECT T3.name FROM assignedto AS T1 JOIN projects AS T2 ON T1.project = T2.code JOIN scientists AS T3 ON T1.scientist = T3.SSN WHERE T2.name = 'Matter of Time' INTERSECT SELECT T3.name FROM assignedto AS T1 JOIN projects AS T2 ON T1.project = T2.code JOIN scientists AS T3 ON T1.scientist = T3.SSN WHERE T2.name = 'A Puzzling Parallax'</s>
{ "answer": "SELECT T3.name FROM assignedto AS T1 JOIN projects AS T2 ON T1.project = T2.code JOIN scientists AS T3 ON T1.scientist = T3.SSN WHERE T2.name = 'Matter of Time' INTERSECT SELECT T3.name FROM assignedto AS T1 JOIN projects AS T2 ON T1.project = T2.code JOIN scientists AS T3 ON T1.scientist = T3.SSN WHERE T2.name = 'A Puzzling Parallax'", "context": "CREATE TABLE projects (code VARCHAR, name VARCHAR); CREATE TABLE scientists (name VARCHAR, SSN VARCHAR); CREATE TABLE assignedto (project VARCHAR, scientist VARCHAR)", "question": "Find the name of the scientist who worked on both a project named 'Matter of Time' and a project named 'A Puzzling Parallax'." }
### QUESTION Find the number of scientists involved for each project name. ### CONTEXT CREATE TABLE assignedto (project VARCHAR); CREATE TABLE projects (name VARCHAR, code VARCHAR) ### ANSWER SELECT COUNT(*), T1.name FROM projects AS T1 JOIN assignedto AS T2 ON T1.code = T2.project GROUP BY T1.name</s>
{ "answer": "SELECT COUNT(*), T1.name FROM projects AS T1 JOIN assignedto AS T2 ON T1.code = T2.project GROUP BY T1.name", "context": "CREATE TABLE assignedto (project VARCHAR); CREATE TABLE projects (name VARCHAR, code VARCHAR)", "question": "Find the number of scientists involved for each project name." }
### QUESTION Find the number of projects which each scientist is working on and scientist's name. ### CONTEXT CREATE TABLE scientists (name VARCHAR, ssn VARCHAR); CREATE TABLE assignedto (scientist VARCHAR) ### ANSWER SELECT COUNT(*), T1.name FROM scientists AS T1 JOIN assignedto AS T2 ON T1.ssn = T2.scientist GROUP BY T1.name</s>
{ "answer": "SELECT COUNT(*), T1.name FROM scientists AS T1 JOIN assignedto AS T2 ON T1.ssn = T2.scientist GROUP BY T1.name", "context": "CREATE TABLE scientists (name VARCHAR, ssn VARCHAR); CREATE TABLE assignedto (scientist VARCHAR)", "question": "Find the number of projects which each scientist is working on and scientist's name." }
### QUESTION Find the SSN and name of scientists who are assigned to the project with the longest hours. ### CONTEXT CREATE TABLE scientists (ssn VARCHAR, name VARCHAR, SSN VARCHAR); CREATE TABLE projects (code VARCHAR, hours INTEGER); CREATE TABLE assignedto (project VARCHAR, scientist VARCHAR); CREATE TABLE projects (hours INTEGER) ### ANSWER SELECT T3.ssn, T3.name FROM assignedto AS T1 JOIN projects AS T2 ON T1.project = T2.code JOIN scientists AS T3 ON T1.scientist = T3.SSN WHERE T2.hours = (SELECT MAX(hours) FROM projects)</s>
{ "answer": "SELECT T3.ssn, T3.name FROM assignedto AS T1 JOIN projects AS T2 ON T1.project = T2.code JOIN scientists AS T3 ON T1.scientist = T3.SSN WHERE T2.hours = (SELECT MAX(hours) FROM projects)", "context": "CREATE TABLE scientists (ssn VARCHAR, name VARCHAR, SSN VARCHAR); CREATE TABLE projects (code VARCHAR, hours INTEGER); CREATE TABLE assignedto (project VARCHAR, scientist VARCHAR); CREATE TABLE projects (hours INTEGER)", "question": "Find the SSN and name of scientists who are assigned to the project with the longest hours." }
### QUESTION Which Year completed has a Dam type of earthfill embankment, and a Dam constructed of khancoban dam? ### CONTEXT CREATE TABLE table_name_25 (year_completed INTEGER, dam_type VARCHAR, dam_constructed VARCHAR) ### ANSWER SELECT MAX(year_completed) FROM table_name_25 WHERE dam_type = "earthfill embankment" AND dam_constructed = "khancoban dam"</s>
{ "answer": "SELECT MAX(year_completed) FROM table_name_25 WHERE dam_type = \"earthfill embankment\" AND dam_constructed = \"khancoban dam\"", "context": "CREATE TABLE table_name_25 (year_completed INTEGER, dam_type VARCHAR, dam_constructed VARCHAR)", "question": "Which Year completed has a Dam type of earthfill embankment, and a Dam constructed of khancoban dam?" }