sentence
stringlengths
3
347
sql
stringlengths
18
804
what is the characteristic data type of characteristic id 1
select characteristic_data_type from Characteristics where characteristic_id = 1
Find the incident type code of behavior incidents of students with the last name "Fahey"?
SELECT T1.incident_type_code FROM Behavior_Incident AS T1 JOIN Students AS T2 ON T1.student_id = T2.student_id WHERE T2.last_name = "Fahey"
How many golds for Canada (12 total)?
SELECT gold FROM table_name_7 WHERE total > 12 AND nation = "canada"
What is the oldest age of the users in 2014's survey?
SELECT T2.AnswerText FROM Question AS T1 INNER JOIN Answer AS T2 ON T1.questionid = T2.QuestionID WHERE T1.questiontext = 'What is your age?' AND T2.SurveyID = 2014 ORDER BY T2.AnswerText DESC LIMIT 1
What is Prize, when Winner is "John Shaw"?
SELECT prize FROM table_name_21 WHERE winner = "john shaw"
List the all the distinct names of the products with the characteristic name 'warm'.
SELECT DISTINCT t1.product_name FROM products AS t1 JOIN product_characteristics AS t2 ON t1.product_id = t2.product_id JOIN CHARACTERISTICS AS t3 ON t2.characteristic_id = t3.characteristic_id WHERE t3.characteristic_name = "warm"
What is the sum of Silver with a Bronze that is larger than 0 with a Gold smaller than 0?
SELECT SUM(silver) FROM table_name_26 WHERE bronze > 0 AND gold < 0
Which league goals has FA cup apps of 2?
SELECT league_goals FROM table_name_39 WHERE fa_cup_apps = 2
What are the names and dates for documents corresponding to project that has the details 'Graph Database project'?
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'
What is Winner, when Date is "20 August"?
SELECT winner FROM table_name_50 WHERE date = "20 august"
What is the record at the neutral site for when the overall record is ui, 27-16?
SELECT at_neutral_site FROM table_16201038_4 WHERE overall_record = "UI, 27-16"
Show the nations that have both journalists with more than 10 years of working and journalists with less than 3 years of working.
SELECT Nationality FROM journalist WHERE Years_working > 10 INTERSECT SELECT Nationality FROM journalist WHERE Years_working < 3
For the business with great experience existed in Sun Lakes city, provide the user ID who gave review on it and user followers.
SELECT T3.user_id, T3.user_fans FROM Business AS T1 INNER JOIN Reviews AS T2 ON T1.business_id = T2.business_id INNER JOIN Users AS T3 ON T2.user_id = T3.user_id WHERE T1.city = 'Sun Lakes' AND T1.stars = 5
List the name of singers that do not have any song.
SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)
Which catalog did Village Records have on February 14, 2002?
SELECT catalog FROM table_name_60 WHERE label = "village records" AND date = "february 14, 2002"
How many employees are there all together?
SELECT count(*) FROM employee
What spacecraft had an EVA that ended at 17:28?
SELECT spacecraft FROM table_name_66 WHERE end_time = "17:28"
How many viewers were there on 1august1964?
SELECT viewers__in_millions_ FROM table_1723080_1 WHERE broadcast_date = "1August1964"
What is the percentage of Atheism associated with an other percentage of 0.08%?
SELECT atheism FROM table_name_90 WHERE other = "0.08%"
Provide the authors and titles of the books which have more than 3000 pages.
SELECT T3.author_name, T1.title FROM book AS T1 INNER JOIN book_author AS T2 ON T1.book_id = T2.book_id INNER JOIN author AS T3 ON T3.author_id = T2.author_id WHERE T1.num_pages > 3000
Which venue has 13,634 people in attendance?
SELECT venue FROM table_name_57 WHERE attendance = "13,634"
What is the latitude of vaidilute rupes?
SELECT latitude FROM table_16799784_3 WHERE name = "Vaidilute Rupes"
Name the most abama number for mccain being 29266
SELECT MAX(obama_number) FROM table_20468206_1 WHERE mccain_number = 29266
Find the total number of players.
SELECT count(*) FROM players
What are the birth places that are shared by at least two people?
SELECT Birth_Place FROM people GROUP BY Birth_Place HAVING COUNT(*) >= 2
what is the episode # for production code 227
SELECT episode__number FROM table_10269427_3 WHERE production_code = 227
Which away team played against Peterborough United, with a tie no of replay?
SELECT away_team FROM table_name_85 WHERE tie_no = "replay" AND home_team = "peterborough united"
Find the origins from which more than 1 train starts.
SELECT origin FROM train GROUP BY origin HAVING count(*) > 1
When 21 is the number in series what is the air date?
SELECT original_air_date FROM table_2409041_2 WHERE no_in_series = 21
List the names of all players from Avangard Omsk who played in the 2000-2001 season of the International league that have no goals in draft year.
SELECT T2.PlayerName FROM SeasonStatus AS T1 INNER JOIN PlayerInfo AS T2 ON T1.ELITEID = T2.ELITEID WHERE T1.SEASON = '2000-2001' AND T1.LEAGUE = 'International' AND T1.TEAM = 'Czech Republic (all)' AND T1.G = 0
Which race has a distance of 201.44 miles?
SELECT race FROM table_name_71 WHERE distance = "201.44 miles"
What is Hong's singles record?
SELECT singles_WL from player where player like "%Hong%"
who had a last performance of 3 july 2011?
SELECT name FROM table_name_18 WHERE last_performance = "3 july 2011"
Which position had a goal difference of less than 27, lost more than 13 games, scored less than 42 goals and drew 6 games?
SELECT MAX(played) FROM table_name_61 WHERE goal_difference < 27 AND losses > 13 AND goals_for < 42 AND draws = 6
What was d. a. weibring's to par?
SELECT to_par FROM table_name_39 WHERE player = "d. a. weibring"
Which buildings have a General Electric then?
SELECT T2.name FROM Office_locations AS T1 JOIN buildings AS T2 ON T1.building_id = T2.id JOIN Companies AS T3 ON T1.company_id = T3.id where T3.name = "General Electric"
Who did they play at lincoln financial field at 8:30 (ET) after week 14?
SELECT opponent FROM table_name_88 WHERE week > 14 AND game_site = "lincoln financial field" AND time__et_ = "8:30"
What type of decor in room name Abscond or bolster?
SELECT decor FROM Rooms where roomname = "Abscond or bolster"
Which circuit was held on 25–28 march?
SELECT circuit FROM table_26686908_2 WHERE date = "25–28 March"
what is the goals when the country is wal, the name is smith and apps is more than 0?
SELECT SUM(goals) FROM table_name_83 WHERE country = "wal" AND name = "smith" AND apps > 0
List the name of the aircraft that has been named winning aircraft the most number of times.
SELECT T1.Aircraft FROM aircraft AS T1 JOIN MATCH AS T2 ON T1.Aircraft_ID = T2.Winning_Aircraft GROUP BY T2.Winning_Aircraft ORDER BY COUNT(*) DESC LIMIT 1
What position did the #10 draft pick play?
SELECT position FROM table_1004033_1 WHERE draft_pick__number = "10"
Tell me north america for january 23, 2013
SELECT north_america FROM table_name_83 WHERE japan = "january 23, 2013"
Who was the winner when the time was 1:24.00?
SELECT winner_2nd FROM table_1360997_2 WHERE time = "1:24.00"
Show the id, name of each editor and the number of journal committees they are on.
SELECT T1.editor_id , T1.Name , COUNT(*) FROM editor AS T1 JOIN journal_committee AS T2 ON T1.Editor_ID = T2.Editor_ID GROUP BY T1.editor_id
Return the names of cities that have a population between 160000 and 900000 .
select name from city where population between 160000 and 900000
List the sales ID of the product with a quantity of 590 and named "External Lock Washer 7".
SELECT T1.SalesID FROM Sales AS T1 INNER JOIN Products AS T2 ON T1.ProductID = T2.ProductID WHERE T2.Name = 'External Lock Washer 7' AND T1.Quantity = 590
Who had the high assists for game 49?
SELECT high_assists FROM table_11907963_6 WHERE game = 49
Which is the charity that the background of the celebrity is heavyweight champion?
SELECT charity FROM table_12286195_1 WHERE background = "Heavyweight Champion"
List the date of perpetrators in descending order of the number of people killed.
SELECT Date FROM perpetrator ORDER BY Killed DESC
What Player is from the Country United States and Money ($) of 356?
SELECT player FROM table_name_24 WHERE country = "united states" AND money___$__ = 356
how many pos with member association being china pr
SELECT COUNT(pos) FROM table_14460937_2 WHERE member_association = "China PR"
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.
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'
Name the Years as tallest that has Height metres / ft of 01.0 27 / 90?
SELECT years_as_tallest FROM table_name_14 WHERE height_metres___ft = "01.0 27 / 90"
Find all the catalog publishers whose name contains "Murray"
SELECT DISTINCT (catalog_publisher) FROM catalogs WHERE catalog_publisher LIKE "%Murray%"
What are the ids of all female students who play football?
SELECT StuID FROM Student WHERE sex = 'F' INTERSECT SELECT StuID FROM Sportsinfo WHERE sportname = "Football"
How many students have been absent less than 4 months?
SELECT COUNT(name) FROM longest_absense_from_school WHERE month < 4
What is the latitude and longitude for Surveyor 3?
SELECT lat___lon FROM table_name_87 WHERE us_mission = "surveyor 3"
can you please show me all the female architects?
SELECT name FROM architect WHERE gender = 'male'
What are the last names of the students that minor in the department with DNO 140?
SELECT T2.Lname FROM MINOR_IN AS T1 JOIN STUDENT AS T2 ON T1.StuID = T2.StuID WHERE T1.DNO = 140
What date was at Oakland-Alameda County Coliseum with a time of 3:40 and a game less than 5?
SELECT date FROM table_name_6 WHERE game < 5 AND location = "oakland-alameda county coliseum" AND time = "3:40"
What is the name and opening year for the branch that registered the most members in 2016?
SELECT T2.name , T2.open_year FROM membership_register_branch AS T1 JOIN branch AS T2 ON T1.branch_id = T2.branch_id WHERE T1.register_year = 2016 GROUP BY T2.branch_id ORDER BY count(*) DESC LIMIT 1
What is the earliest any of these players were born?
SELECT MIN(year_born) FROM table_12962773_10
Who all played mixed doubles in 2010?
SELECT mixed_doubles FROM table_name_68 WHERE year = 2010
What is the latest year for a Emeryson 1006 chassis with more than 0 points?
SELECT MAX(year) FROM table_name_37 WHERE chassis = "emeryson 1006" AND points > 0
Who is the lead for the team with Christina Haller as alternate?
SELECT lead FROM table_name_86 WHERE alternate = "christina haller"
How many games were played by the player who had 22 penalty minutes?
SELECT games FROM table_name_52 WHERE pen_min = "22"
What was the inroductory phase for the episode that originally aired january 21?
SELECT introductory_phrase FROM table_14835674_1 WHERE original_airdate = "January 21"
What is the number of pole position with a round of 15?
SELECT COUNT(pole_position) FROM table_1137707_2 WHERE round = 15
What was the score on October 24, 2005?
SELECT score FROM table_name_55 WHERE date = "october 24, 2005"
What is the number of players whose last name is Green that played in the league but not coached?
SELECT COUNT(playerID) FROM Master WHERE lastName = 'Green' AND coachID IS NULL
Which company was based in London, United Kingdom?
SELECT institution FROM table_15438337_1 WHERE country = "London, United Kingdom"
What party was re-elected to Virginia 12?
SELECT party FROM table_2668420_17 WHERE result = "Re-elected" AND district = "Virginia 12"
What is the last name of Reservations Code 10105?
SELECT LastName from Reservations where Code = 10105
What is the percentage of male athletes from Estonia?
SELECT CAST(COUNT(CASE WHEN T3.gender = 'M' THEN 1 ELSE NULL END) AS REAL) * 100 / COUNT(T2.person_id) FROM noc_region AS T1 INNER JOIN person_region AS T2 ON T1.id = T2.region_id INNER JOIN person AS T3 ON T2.person_id = T3.id WHERE T1.region_name = 'Estonia'
Which location has the most corresponding counties?
SELECT LOCATION FROM county_public_safety GROUP BY LOCATION ORDER BY COUNT(*) DESC LIMIT 1
what type of institution is ottawa university?
SELECT type FROM table_262527_1 WHERE institution = "Ottawa University"
Which memeber has nt as the state?
SELECT member FROM table_name_7 WHERE state = "nt"
Show names for all aircrafts of which John Williams has certificates.
SELECT T3.name FROM Employee AS T1 JOIN Certificate AS T2 ON T1.eid = T2.eid JOIN Aircraft AS T3 ON T3.aid = T2.aid WHERE T1.name = "John Williams"
What was the nationality of the swimmer in the semifinal with a time of 29.51?
SELECT nationality FROM table_name_62 WHERE round = "semifinal" AND time = "29.51"
can you show me a list of active from date?
select active_from_date from customer_contact_channels
In which position did Iljuštšenko finish in the European Championships held prior to 2008?
SELECT position FROM table_name_48 WHERE year < 2008 AND competition = "european championships"
Tell me the affiliation for mls team of metrostars and pick number of 26
SELECT affiliation FROM table_name_28 WHERE mls_team = "metrostars" AND pick__number = 26
How many Number of Platforms in station id 2?
select number_of_platforms from station where station_id = 2
What type of transaction was made with the only yellow product, size 62 and with a minimum inventory stock of 500 units?
SELECT DISTINCT T2.TransactionType FROM Product AS T1 INNER JOIN TransactionHistory AS T2 ON T1.ProductID = T2.ProductID WHERE T1.Size = 62 AND T1.Color = 'Yellow' AND T1.SafetyStockLevel = 500
Among the universities with a score in teaching of over 90 in 2011, how many of them are in the United States of America?
SELECT COUNT(*) FROM ranking_criteria AS T1 INNER JOIN university_ranking_year AS T2 ON T1.id = T2.ranking_criteria_id INNER JOIN university AS T3 ON T3.id = T2.university_id WHERE T1.criteria_name = 'Teaching' AND T2.year = 2011 AND T2.score > 90
What country is he from?
SELECT T2.country FROM exhibition AS T1 JOIN artist AS T2 ON T1.artist_id = T2.artist_id GROUP BY T1.artist_id ORDER BY count ( * ) DESC LIMIT 1
Show the race class and number of races in each class.
SELECT CLASS, COUNT(*) FROM race GROUP BY CLASS
list out the all machine id
SELECT machine_id FROM repair_assignment
What is the total amount of products purchased before 2018-03-17 07:13:53?
SELECT sum(t2.order_quantity) FROM customer_orders AS t1 JOIN order_items AS t2 ON t1.order_id = t2.order_id WHERE t1.order_date < '2018-03-17 07:13:53'
List the states where both the secretary of 'Treasury' department and the secretary of 'Homeland Security' were born.
SELECT T3.born_state FROM department AS T1 JOIN management AS T2 ON T1.department_id = T2.department_id JOIN head AS T3 ON T2.head_id = T3.head_id WHERE T1.name = 'Treasury' INTERSECT SELECT T3.born_state FROM department AS T1 JOIN management AS T2 ON T1.department_id = T2.department_id JOIN head AS T3 ON T2.head_id = T3.head_id WHERE T1.name = 'Homeland Security'
what are the names of the players?
SELECT Player_name FROM Player
Show year where a track with a seating at least 5000 opened and a track with seating no more than 4000 opened.
SELECT year_opened FROM track WHERE seating BETWEEN 4000 AND 5000
For each team, how many technicians are there?
SELECT Team , COUNT(*) FROM technician GROUP BY Team
What was the score for the game against Houston?
SELECT score FROM table_23285761_10 WHERE team = "Houston"
And what about the accounting department?
SELECT count ( * ) FROM professor AS T1 JOIN department AS T2 ON T1.dept_code = T2.dept_code WHERE DEPT_NAME = "Accounting"
How many were in attendance against the Oakland Raiders after week 7?
SELECT SUM(attendance) FROM table_name_25 WHERE opponent = "oakland raiders" AND week > 7
What is the lowest enrollment amount for a year left of 2012 and a current conference of Mid-South?
SELECT MIN(enrollment) FROM table_name_17 WHERE left = 2012 AND current_conference = "mid-south"
List every album whose title starts with A in alphabetical order.
SELECT title FROM albums WHERE title LIKE 'A%' ORDER BY title;
What is Brian Mateer's Speed?
SELECT speed FROM table_name_1 WHERE rider = "brian mateer"