sentence
stringlengths
3
347
sql
stringlengths
18
804
List the most common result of the musicals.
SELECT RESULT FROM musical GROUP BY RESULT ORDER BY COUNT(*) DESC LIMIT 1
Name the total number of trofeo fast team of stage 16
SELECT COUNT(trofeo_fast_team) FROM table_12261806_2 WHERE stage = "16"
What is the age of Breton,Robert?
SELECT age FROM member where Name = 'Breton, Robert'
What is the Craft used at Coniston Water?
SELECT craft FROM table_name_15 WHERE location = "coniston water"
Report the name of all campuses in Los Angeles county.
SELECT campus FROM campuses WHERE county = "Los Angeles"
Which entrant, with an Offenhauser L4 engine and a Kurtis Kraft KK500A chassis, scored 9 points before 1955?
SELECT entrant FROM table_name_15 WHERE engine = "offenhauser l4" AND year < 1955 AND chassis = "kurtis kraft kk500a" AND points = 9
What's the hometown of the player who went to lsu?
SELECT hometown FROM table_name_32 WHERE college = "lsu"
tell me the staff details of staff id 1 ?
SELECT staff_details FROM Research_Staff where staff_id = 1
How many matches did the Sunrisers Hyderabad team win in 2013?
SELECT SUM(CASE WHEN Match_Date LIKE '2013%' THEN 1 ELSE 0 END) FROM `Match` AS T1 INNER JOIN Team AS T2 ON T1.Match_Winner = T2.Team_Id WHERE T2.Team_Name = 'Sunrisers Hyderabad'
What was the To par for bill britton when he placed t7?
SELECT to_par FROM table_name_37 WHERE place = "t7" AND player = "bill britton"
What is the most gold when the rank is 7 and bronze is less than 0?
SELECT MAX(gold) FROM table_name_40 WHERE rank = "7" AND bronze < 0
list all the venues of the the debates
SELECT Venue FROM debate
What are the distinct first names of the students who have vice president votes and reside in a city whose city code is not PIT?
SELECT DISTINCT T1.Fname FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID = T2.VICE_PRESIDENT_Vote EXCEPT SELECT DISTINCT Fname FROM STUDENT WHERE city_code = "PIT"
What is the latest episode number that was directed by Tom Dicillo?
SELECT MAX(no_in_series) FROM table_28561455_1 WHERE directed_by = "Tom DiCillo"
Among all the employees who don't wish to receive promotion e-mails, how many of them belong to or once belonged to the Engineering Department?
SELECT COUNT(T1.BusinessEntityID) FROM EmployeeDepartmentHistory AS T1 INNER JOIN Person AS T2 ON T1.BusinessEntityID = T2.BusinessEntityID INNER JOIN Department AS T3 ON T1.DepartmentID = T3.DepartmentID WHERE T3.Name = 'Engineering' AND T2.EmailPromotion = 0
Determine the number of shipments delivered by Andrea Simons to Huntsville in 2016.
SELECT COUNT(*) FROM shipment AS T1 INNER JOIN city AS T2 ON T1.city_id = T2.city_id INNER JOIN driver AS T3 ON T3.driver_id = T1.driver_id WHERE T3.first_name = 'Andrea' AND T3.last_name = 'Simons' AND T2.city_name = 'Huntsville' AND STRFTIME('%Y', T1.ship_date) = '2016'
What are the countries of perpetrators? Show each country and the corresponding number of perpetrators there.
SELECT Country, COUNT(*) FROM perpetrator GROUP BY Country
What company is the producer at the poolavadi location
SELECT producer FROM table_name_99 WHERE location = "poolavadi"
what are the color descriptions for the products? | Do you want both the names and the color descriptions? | yes
SELECT T1.product_name , T2.color_description FROM products AS T1 JOIN Ref_colors AS T2 ON T1.color_code = T2.color_code WHERE product_category_code = "Herbs"
Find the campus fee of "San Jose State University" in year 2000.
SELECT t1.campusfee FROM csu_fees AS t1 JOIN campuses AS t2 ON t1.campus = t2.id WHERE t2.campus = "San Jose State University" AND t1.year = 2000
what is the previous conference when the location is converse?
SELECT previous_conference FROM table_name_69 WHERE location = "converse"
What country is the Debemur Morti prod. label from?
SELECT country FROM table_name_97 WHERE label = "debemur morti prod."
What is the total for University of Dublin, having a panel of 0 for agricultural, was nominated by Taoiseach more than 0, and an industrial and commercial panel less than 0?
SELECT COUNT(university_of_dublin) FROM table_name_94 WHERE agricultural_panel = 0 AND nominated_by_the_taoiseach > 0 AND industrial_and_commercial_panel < 0
what is the date from of staff id 779.0
SELECT date_from FROM Project_Staff where staff_id = 779.0
What was the segment b for Netflix s01e21?
SELECT segment_b FROM table_name_34 WHERE netflix = "s01e21"
What was the final score of the Paul Goldstein match?
SELECT score FROM table_name_96 WHERE opponent_in_the_final = "paul goldstein"
What was the edition after 2003 when the Third was Tikveš and Sileks was the runner-up?
SELECT MIN(edition) FROM table_name_64 WHERE year > 2003 AND third = "tikveš" AND runner_up = "sileks"
can you list the engineer id, first name, and last name of the engineer who had the least number of visits?
SELECT T1.engineer_id , T1.first_name , T1.last_name ,count ( * ) FROM Maintenance_Engineers AS T1 JOIN Engineer_Visits AS T2 ON T1.engineer_id = T2.engineer_id GROUP BY T1.engineer_id ORDER BY count ( * ) limit 1
What was the most popular position at tryouts?
SELECT pPos FROM tryout GROUP BY pPos ORDER BY count(*) DESC LIMIT 1
What are the main services of that station?
SELECT T2.Main_Services FROM train_station AS T1 JOIN station AS T2 ON T1.station_id = T2.station_id GROUP BY T1.station_id ORDER BY count ( * ) DESC LIMIT 1
* I have left the chat *
SELECT file_size,formats FROM files AS T1 JOIN song AS T2 ON T1.f_id = T2.f_id GROUP BY T2.languages ORDER BY T2.languages
In what rounds did Scuderia Milano participate?
SELECT rounds FROM table_name_48 WHERE entrant = "scuderia milano"
What is the name of the company that constructed the vehicle for Timo Glock?
SELECT constructor FROM table_name_15 WHERE driver = "timo glock"
How much is the car with the highest sweep volume?
SELECT T2.price FROM data AS T1 INNER JOIN price AS T2 ON T1.ID = T2.ID ORDER BY T1.displacement / T1.cylinders DESC LIMIT 1
show all the procedures on the table | Did you want all the procedure names? | exactly
SELECT Name FROM Procedures
Name the stage for no award
SELECT stage FROM table_22713796_14 WHERE mountains_classification = "no award"
Return the template type code of the template that is used by a document named Data base.
SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = "Data base"
what is the id of balls to the walls
SELECT distinct T2.id FROM albums AS T1 JOIN tracks AS T2 ON T1.id = T2.genre_id WHERE T1.title = "Balls to the Wall"
Tell me the 1968 for 1r
SELECT 1968 FROM table_name_76 WHERE 1967 = "1r"
What is the total silver with a Rank larger than 9, and a Total larger than 1?
SELECT SUM(silver) FROM table_name_94 WHERE rank > 9 AND total > 1
Which player had a rank of 8 and tally of 1-5?
SELECT player FROM table_name_56 WHERE rank = 8 AND tally = "1-5"
What is the highest labour panel when the university of dublin is less than 2 and the agricultural panel is greater than 5?
SELECT MAX(labour_panel) FROM table_name_46 WHERE university_of_dublin < 2 AND agricultural_panel > 5
which gender got the highest average uncertain ratio.
SELECT t1.sex FROM people AS t1 JOIN candidate AS t2 ON t1.people_id = t2.people_id GROUP BY t1.sex ORDER BY avg(t2.unsure_rate) DESC LIMIT 1
How many times more is the number of games which were published by Atari than Athena?
SELECT CAST(COUNT(CASE WHEN T1.publisher_name = 'Atari' THEN T2.game_id ELSE NULL END) AS REAL) / COUNT(CASE WHEN T1.publisher_name = 'Athena' THEN T2.game_id ELSE NULL END) FROM publisher AS T1 INNER JOIN game_publisher AS T2 ON T1.id = T2.publisher_id
What is the 2nd ratio of 1996-2002 Dodge Viper?
SELECT 2 AS nd FROM table_1310499_1 WHERE application = "1996-2002 Dodge Viper"
What kind of Week 2 has a Week 4 of araya robinson?
SELECT week_2 FROM table_name_15 WHERE week_4 = "araya robinson"
List the employees' full names and ages in 2022 who lived in London.
SELECT TitleOfCourtesy, FirstName, LastName , TIMESTAMPDIFF(YEAR, BirthDate, NOW()) AS ages FROM Employees WHERE City = 'London'
What are all role codes?
SELECT role_code FROM ROLES
Can you tell me the average Total that had the Silver of 0, and the Rank of 6, and the Gold smaller than 0?
SELECT AVG(total) FROM table_name_92 WHERE silver = 0 AND rank = "6" AND gold < 0
What incumbent was a federalist that was first elected in 1803?
SELECT incumbent FROM table_2668374_18 WHERE party = "Federalist" AND first_elected = "1803"
What school/club team did Amal McCaskill play for?
SELECT school_club_team FROM table_name_40 WHERE player = "amal mccaskill"
What is the maximum capacity of the San Agustin Gym?
SELECT maximum_seating_capacity FROM table_name_91 WHERE arena_venue = "san agustin gym"
what is the position when the pick is higher than 33 and the school is tottenville hs (staten island, ny)?
SELECT position FROM table_name_16 WHERE pick > 33 AND school = "tottenville hs (staten island, ny)"
Compute the total order quantities of the product "photo".
SELECT sum(T1.Order_Quantity) FROM ORDER_ITEMS AS T1 JOIN Products AS T2 ON T1.Product_ID = T2.Product_ID WHERE T2.Product_Name = "photo"
Show the name for regions not affected.
SELECT region_name FROM region WHERE region_id NOT IN (SELECT region_id FROM affected_region);
Name the sum of frequency will call sign of k259aw
SELECT SUM(frequency_mhz) FROM table_name_67 WHERE call_sign = "k259aw"
What are the names and ids of stations that had more than 14 bikes available on average or were installed in December?
SELECT T1.name, T1.id FROM station AS T1 JOIN status AS T2 ON T1.id = T2.station_id GROUP BY T2.station_id HAVING AVG(T2.bikes_available) > 14 UNION SELECT name, id FROM station WHERE installation_date LIKE "12/%"
What is the total work number of Gowrie after 1875?
SELECT SUM(works_number) FROM table_name_45 WHERE date > 1875 AND name = "gowrie"
What are the countries where either English or Dutch is the official language ?
select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = "english" and isofficial = "t" union select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = "dutch" and isofficial = "t"
Name the total number of opponent of record 9-2
SELECT COUNT(opponent) FROM table_17186229_4 WHERE record = "9-2"
In 1976, how many goals achieved by team 'BIR' in Division 'EW'?
SELECT SUM(T2.G) FROM Teams AS T1 INNER JOIN Scoring AS T2 ON T1.tmID = T2.tmID AND T1.year = T2.year WHERE T1.divID = 'EW' AND T1.tmID = 'BIR' AND T1.year = 1976
Show the first and last name of all the faculty members who participated in some activity, together with the number of activities they participated in.
SELECT T1.fname , T1.lname , count(*) FROM Faculty AS T1 JOIN Faculty_participates_in AS T2 ON T1.facID = T2.facID GROUP BY T1.FacID
Where is bobby jones (a)?
SELECT place FROM table_name_43 WHERE player = "bobby jones (a)"
Which Tournament has a 2007 of wta premier 5 tournaments?
SELECT tournament FROM table_name_28 WHERE 2007 = "wta premier 5 tournaments"
What is the 1988 result that has a 1994 result of A, and 3r as the 1987 result?
SELECT 1988 FROM table_name_19 WHERE 1994 = "a" AND 1987 = "3r"
What is the batting style of Makhaya Ntini?
SELECT batting_style FROM table_name_85 WHERE player = "makhaya ntini"
Which Attendance has a Game score less than 3, and a Score of 2 – 5?
SELECT AVG(attendance) FROM table_name_58 WHERE game < 3 AND score = "2 – 5"
What is the percentage of females where the state code is a 4?
SELECT females___percentage_ FROM table_14598_9 WHERE state_ut_code = 4
What was the record when the game was played at Cleveland Municipal Stadium?
SELECT record FROM table_14984078_1 WHERE game_site = "Cleveland Municipal Stadium"
Which site has the CERCLIS ID fld004092532?
SELECT name FROM table_name_88 WHERE cerclis_id = "fld004092532"
List the range distroration for the ramsan-630
SELECT form_factor FROM table_27615520_1 WHERE product_name = "RamSan-630"
how many campuses are presented on the table
SELECT count ( * ) FROM campuses
Find the name of the customers who have at most two orders.
SELECT T2.customer_name FROM orders AS T1 JOIN customers AS T2 ON T1.customer_id = T2.customer_id GROUP BY T2.customer_id HAVING COUNT(*) <= 2
What is the highest Quantity for PTRD Nos. 3, 15?
SELECT MAX(quantity) FROM table_name_84 WHERE ptrd_nos = "3, 15"
Please list the names of all the customers who had ordered the product "Telescoping Adjustable Floor Lamp".
SELECT DISTINCT T1.`Customer Name` FROM people AS T1 INNER JOIN central_superstore AS T2 ON T1.`Customer ID` = T2.`Customer ID` INNER JOIN product AS T3 ON T3.`Product ID` = T2.`Product ID` WHERE T3.`Product Name` = 'Telescoping Adjustable Floor Lamp'
Find all the songs that do not have a back vocal.
SELECT DISTINCT title FROM vocals AS t1 JOIN songs AS t2 ON t1.songid = t2.songid EXCEPT SELECT t2.title FROM vocals AS t1 JOIN songs AS t2 ON t1.songid = t2.songid WHERE TYPE = "back"
How many policies does America Jaskolski have listed?
SELECT count ( * ) FROM customers AS t1 JOIN customers_policies AS t2 ON t1.customer_id = t2.customer_id where Customer_name = "America Jaskolski"
What circuit has qualifying as the session?
SELECT circuit FROM table_name_77 WHERE session = "qualifying"
Who was the loser playing football with england b as a winner after 1992?
SELECT loser FROM table_name_55 WHERE sport = "football" AND winner = "england b" AND date > 1992
What is the highest number of enrollments? | do you mean the highest number of course enrollments of student? | yes
SELECT count ( * ) FROM Student_Course_Enrolment AS T1 JOIN Students AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY COUNT ( * ) DESC LIMIT 1
What is the longest trip duration according? Convert the it to number of days.
SELECT MAX(duration), CAST(MAX(duration) AS REAL) / 86400 FROM trip
How many students did Harvard University have in 2011?
SELECT T1.num_students FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id WHERE T2.university_name = 'Harvard University' AND T1.year = 2011
What position did Jimmy Oliver of the United States play?
SELECT position FROM table_name_75 WHERE nationality = "united states" AND player = "jimmy oliver"
What is the date in location from for this document?
SELECT T2.Date_in_Location_From from all_documents as T1 join Document_Locations as T2 on T1.document_id = T2.document_id where T1.document_name = "Robin CV"
Find the name of the item with the lowest average rating.
SELECT T1.title FROM item AS T1 JOIN review AS T2 ON T1.i_id = T2.i_id GROUP BY T2.i_id ORDER BY avg(T2.rating) LIMIT 1
State the total number of the attribute classes.
SELECT COUNT(ATT_CLASS_ID) FROM ATT_CLASSES
Could you find the names of all the departments, please?
SELECT dept_name FROM department
What is the payment method of the customer that has purchased the least quantity of items?
SELECT t1.payment_method FROM customers AS t1 JOIN customer_orders AS t2 ON t1.customer_id = t2.customer_id JOIN order_items AS t3 ON t2.order_id = t3.order_id GROUP BY t1.customer_name ORDER BY sum(t3.order_quantity) LIMIT 1
Show the delegates and the names of the party they belong to.
SELECT T1.Delegate , T2.Party FROM election AS T1 JOIN party AS T2 ON T1.Party = T2.Party_ID
What is the pay rate of the employee who has the longest vacation hours?
SELECT T1.Rate FROM EmployeePayHistory AS T1 INNER JOIN Employee AS T2 ON T1.BusinessEntityID = T2.BusinessEntityID ORDER BY T2.VacationHours DESC LIMIT 1
What 20-29 was in season 2008?
SELECT 20 AS _29 FROM table_name_69 WHERE season = "2008"
What is the date when the city is San Antonio, Texas?
SELECT date FROM table_20996923_20 WHERE city = "San Antonio, Texas"
Please list the numbers of males in all the residential areas in Arecibo county.
SELECT SUM(T1.male_population) FROM zip_data AS T1 INNER JOIN country AS T2 ON T1.zip_code = T2.zip_code WHERE T2.county = 'ARECIBO'
Name the number of years for womens doubles being diana koleva emilia dimitrova and jeliazko valkov
SELECT COUNT(year) FROM table_14903491_1 WHERE womens_doubles = "Diana Koleva Emilia Dimitrova" AND mens_singles = "Jeliazko Valkov"
Name the number of shows when there was 2 million views
SELECT COUNT(us_viewers__million_) FROM table_13336122_6 WHERE no_in_season = 2
Before 1956, what Chassis has Gordini Straight-4 engine with 3 points?
SELECT chassis FROM table_name_83 WHERE year < 1956 AND engine = "gordini straight-4" AND points = 3
Name the air date for jay j. demopoulos
SELECT original_air_date FROM table_24466855_1 WHERE written_by = "Jay J. Demopoulos"
How many stroke patients have married?
SELECT COUNT(DISTINCT T1.patient) FROM patients AS T1 INNER JOIN conditions AS T2 ON T1.patient = T2.PATIENT WHERE T2.DESCRIPTION = 'Stroke' AND T1.marital = 'M'
Name the became consort for marriage of 4 april 1721
SELECT became_consort FROM table_name_92 WHERE marriage = "4 april 1721"
Sort the names of all counties in ascending order of population.
SELECT County_name FROM county ORDER BY Population ASC