sentence
stringlengths 3
347
| sql
stringlengths 18
804
|
---|---|
What was the opponent at the game that had a loss of Travers (0–2)? | SELECT opponent FROM table_name_9 WHERE loss = "travers (0–2)" |
How many people attended games at vfl park? | SELECT SUM(crowd) FROM table_name_12 WHERE venue = "vfl park" |
Among author ID of under 1000, who published the paper in affiliation with Zurich, ETH, provide paper ID, year and keyword if any. | SELECT T2.Id, T2.Year, T2.Keyword FROM PaperAuthor AS T1 INNER JOIN Paper AS T2 ON T1.PaperId = T2.Id WHERE T1.AuthorId < 1000 AND T1.Affiliation = 'Zurich, ETH' |
I need to know how many people there are whose age is greater than 30 and job is an engineer. | SELECT count ( * ) FROM Person WHERE age > 30 AND job = 'engineer' |
What is the current address of customer Kandy? | SELECT T3.street_number, T3.street_name, T3.city FROM customer AS T1 INNER JOIN customer_address AS T2 ON T1.customer_id = T2.customer_id INNER JOIN address AS T3 ON T3.address_id = T2.address_id INNER JOIN address_status AS T4 ON T4.status_id = T2.status_id WHERE T1.first_name = 'Kandy' |
Name the Voltage Range which has a FSB Speed of 400 mhz, and a Clock Speed of 1 ghz? | SELECT voltage_range FROM table_name_30 WHERE fsb_speed = "400 mhz" AND clock_speed = "1 ghz" |
What type is shown with a moving to of valenciennes? | SELECT type FROM table_name_7 WHERE moving_to = "valenciennes" |
How many times was frank m. clark the incumbent? | SELECT COUNT(result) FROM table_1341865_40 WHERE incumbent = "Frank M. Clark" |
Can you list just the states which have college students in tryout and their decisions are yes? | SELECT DISTINCT T1.state FROM college AS T1 JOIN tryout AS T2 ON T1.cName = T2.cName WHERE T2.decision = 'yes' |
On what date did the Bills play the Houston Oilers before week 12? | SELECT date FROM table_name_79 WHERE week < 12 AND opponent = "houston oilers" |
Which country has an IATA of gzt? | SELECT country FROM table_name_70 WHERE iata = "gzt" |
I want the time/retired for grid of 24 | SELECT time_retired FROM table_name_12 WHERE grid = 24 |
Who was the man of the match when the Rockets won by 9 wickets? | SELECT man_of_the_match FROM table_19576091_1 WHERE result = "Rockets won by 9 wickets" |
List the airport code and name in the city of Anthony. | SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = "Anthony" |
What is the % (1960) of the county with a % (2040) of 3.4? | SELECT COUNT(_percentage__1960_) FROM table_name_98 WHERE _percentage__2040_ = 3.4 |
Tweet with ID tw-682723090279841798 was posted from which country? | SELECT T2.Country FROM twitter AS T1 INNER JOIN location AS T2 ON T1.LocationID = T2.LocationID WHERE T1.TweetID = 'tw-682723090279841798' |
What is every year born for height of 1.88? | SELECT year_born FROM table_23670057_7 WHERE height__m_ = "1.88" |
Which shops' number products is above the average? Give me the shop names. | SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop) |
What is the total number for November, larger than 8.53 in February, 20.21 in March, and less than 7.9 in September? | SELECT COUNT(november) FROM table_name_50 WHERE february > 8.53 AND march = 20.21 AND september < 7.9 |
Which team had a pick of 63? | SELECT school_club_team FROM table_name_93 WHERE pick = 63 |
hey, which 3 players won the most player awards? list their full name and id | SELECT T1.name_first , T1.name_last , T1.player_id FROM player AS T1 JOIN player_award AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY count ( * ) DESC LIMIT 3 |
Among all the trips, which day had the most bikes borrowed? What was the average coldest temperature on that day? | SELECT T2.date, AVG(T2.min_temperature_f) FROM trip AS T1 INNER JOIN weather AS T2 ON T2.zip_code = T1.zip_code GROUP BY T2.date ORDER BY COUNT(T1.start_date) DESC LIMIT 1 |
Who directed the film Antonio's Breakfast? | SELECT director_s_ FROM table_name_44 WHERE film = "antonio's breakfast" |
and how many are followed by Susan? | SELECT count ( t2.f1 ) FROM user_profiles AS T1 JOIN follows AS T2 ON T1.uid = T2.f2 WHERE T1.name = "Susan" |
List three countries which are the origins of the least players. | SELECT birth_country FROM player GROUP BY birth_country ORDER BY count(*) ASC LIMIT 3; |
What is the Original name of empire of passion? | SELECT original_name FROM table_name_17 WHERE film_title_used_in_nomination = "empire of passion" |
WHich Year has a Music director(s) of anu malik? | SELECT SUM(year) FROM table_name_5 WHERE music_director_s_ = "anu malik" |
WHAT IS THE SHOP ID | Do you mean the shop id for the shop that has the largest quantity of devices in stock? | YES | SELECT T2.shop_id FROM stock AS T1 JOIN shop AS T2 ON T1.Shop_ID = T2.Shop_ID GROUP BY T1.Shop_ID ORDER BY SUM ( T1.quantity ) DESC LIMIT 1 |
What is the average NGC number of everything with a Right ascension (J2000) of 05h33m30s? | SELECT AVG(ngc_number) FROM table_name_7 WHERE right_ascension___j2000__ = "05h33m30s" |
Select the names and the prices of all the products in the store. | SELECT name , price FROM products |
What was the decision of the game when the Lightning had a record of 6–8–1? | SELECT decision FROM table_name_84 WHERE record = "6–8–1" |
Show the member name and hometown who registered a branch in 2016. | SELECT T2.name , T2.hometown FROM membership_register_branch AS T1 JOIN member AS T2 ON T1.member_id = T2.member_id WHERE T1.register_year = 2016 |
Find the first names of the faculty members who are playing Canoeing or Kayaking. | SELECT DISTINCT T1.fname FROM Faculty AS T1 JOIN Faculty_participates_in AS T2 ON T1.facID = T2.facID JOIN activity AS T3 ON T2.actid = T2.actid WHERE T3.activity_name = 'Canoeing' OR T3.activity_name = 'Kayaking' |
What is the hometown of the pitcher who's school was Saint Joseph Regional High School? | SELECT hometown FROM table_11677100_18 WHERE position = "Pitcher" AND school = "Saint Joseph Regional High school" |
Which Webcast has a Callsign of kgbt? | SELECT webcast FROM table_name_91 WHERE callsign = "kgbt" |
What about just the ones with the transaction type code SALE? | Select date_of_transaction from transactions where transaction_type_code = "SALE" |
Show the name of country id 66. | SELECT country_name FROM country WHERE id = 66 |
name the customer which have 15 as customer id? | SELECT customer_name FROM customers where customer_id = 15 |
What are the product ids and color descriptions for products with two or more characteristics? | SELECT t1.product_id , t2.color_description FROM products AS t1 JOIN ref_colors AS t2 ON t1.color_code = t2.color_code JOIN product_characteristics AS t3 ON t1.product_id = t3.product_id GROUP BY t1.product_id HAVING count(*) >= 2 |
What genre is the game 2010 FIFA World Cup South Africa? | SELECT T2.genre_name FROM game AS T1 INNER JOIN genre AS T2 ON T1.genre_id = T2.id WHERE T1.game_name = '2010 FIFA World Cup South Africa' |
Find the number of professors in 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 schools exist in total? | SELECT count(DISTINCT school_code) FROM department |
Name the point with points for of 255 | SELECT points FROM table_name_67 WHERE points_for = "255" |
What are the names of students who have taken Statistics courses? | SELECT T3.name FROM course AS T1 JOIN takes AS T2 ON T1.course_id = T2.course_id JOIN student AS T3 ON T2.id = T3.id WHERE T1.dept_name = 'Statistics' |
What is the total number of draws when there are 1465 against matches and less than 2 byes? | SELECT COUNT(draws) FROM table_name_76 WHERE against = 1465 AND byes < 2 |
Which result's genre was jazz when its label was columbia and its title was requiem? | SELECT result FROM table_name_35 WHERE genre = "jazz" AND label = "columbia" AND title = "requiem" |
Show the people that have been comptroller the most times and the corresponding number of times. | SELECT Comptroller , COUNT(*) FROM party GROUP BY Comptroller ORDER BY COUNT(*) DESC LIMIT 1 |
What is the flight number of the aircraft Thompson drove in March 1, 1963 | SELECT Vehicle_Flight_number FROM flight WHERE pilot = 'Thompson' and date = 'March 1, 1963' |
what is the company when the country is greece and the author is aeschylus? | SELECT company FROM table_name_28 WHERE country = "greece" AND author = "aeschylus" |
what's the dbeingtribution with grsecurity being no | SELECT distribution FROM table_1357052_6 WHERE grsecurity = "No" |
Show the names of journalists and the number of events they reported. | SELECT T3.Name, COUNT(*) FROM news_report AS T1 JOIN event AS T2 ON T1.Event_ID = T2.Event_ID JOIN journalist AS T3 ON T1.journalist_ID = T3.journalist_ID GROUP BY T3.Name |
Calculate the percentage of the winners who are higher than 1.75 meters. | SELECT CAST(SUM(CASE WHEN T1.height_meters > 1.75 THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(*) FROM Person AS T1 INNER JOIN Award AS T2 ON T1.name = T2.person WHERE T2.result = 'Winner'; |
What's the average number of silver medals when bronze is less than 0? | SELECT AVG(silver) FROM table_name_86 WHERE bronze < 0 |
Whare the names, friends, and ages of all people who are older than the average age of a person? | SELECT DISTINCT T2.name , T2.friend , T1.age FROM Person AS T1 JOIN PersonFriend AS T2 ON T1.name = T2.friend WHERE T1.age > (SELECT avg(age) FROM person) |
Name the nfl team for pick number 151 | SELECT nfl_team FROM table_2508633_6 WHERE pick__number = 151 |
What is the percentage of increase of the indicator on Adolescent fertility rate from 1960 to 1961 in the country whose Alpha2Code is 1A? | SELECT (( SELECT T2.Value FROM Country AS T1 INNER JOIN Indicators AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.Alpha2Code = '1A' AND T2.IndicatorName = 'Adolescent fertility rate (births per 1,000 women ages 15-19)' AND T2.Year = 1961 ) - ( SELECT T2.Value FROM Country AS T1 INNER JOIN Indicators AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.Alpha2Code = '1A' AND T2.IndicatorName = 'Adolescent fertility rate (births per 1,000 women ages 15-19)' AND T2.Year = 1960 )) * 1.0 / ( SELECT SUM(T2.Value) FROM Country AS T1 INNER JOIN Indicators AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.Alpha2Code = '1A' AND T2.IndicatorName = 'Adolescent fertility rate (births per 1,000 women ages 15-19)' AND T2.Year = 1960 ) |
What are the monthly rentals of student addresses in Texas state? | SELECT T2.monthly_rental FROM Addresses AS T1 JOIN Student_Addresses AS T2 ON T1.address_id = T2.address_id WHERE T1.state_province_county = "Texas" |
How many games were against Furman? | SELECT MAX(game) FROM table_20745444_1 WHERE opponent = "Furman" |
How many villages have a density persons/ha of 5.5? | SELECT COUNT(no_of_villages) FROM table_21302_1 WHERE density_persons___ha = "5.5" |
Show the number of projects. | SELECT count(*) FROM Projects |
What is the branch ID associated with Myron Pryor? | SELECT t2.branch_id from member as t1 join purchase as t2 on t1.member_id = t2.member_id where name = "Myron Pryor" |
Find the name of persons who are friends with Bob. | SELECT name FROM PersonFriend WHERE friend = 'Bob' |
What are the distinct ids of products ordered between 1975-01-01 and 1976-01-01?? | SELECT DISTINCT T2.product_id FROM orders AS T1 JOIN order_items AS T2 ON T1.order_id = T2.order_id WHERE T1.date_order_placed >= "1975-01-01" AND T1.date_order_placed <= "1976-01-01" |
What is the Staffel A that has a Staffel D of Energie Cottbus and a Staffel C of Chemie Leipzig and a Staffel B of 1. FC Union Berlin? | SELECT staffel_a FROM table_name_75 WHERE staffel_d = "energie cottbus" AND staffel_c = "chemie leipzig" AND staffel_b = "1. fc union berlin" |
What is the Digital/analog signal with an Available interface with pci express, with Retail name with all-in-wonder x600 pro? | SELECT digital_analog_signal FROM table_name_71 WHERE available_interface = "pci express" AND retail_name = "all-in-wonder x600 pro" |
What was the total with a score in set 3 of 13–25? | SELECT total FROM table_name_55 WHERE set_3 = "13–25" |
How many teachers does the student named MADLOCK RAY have? | SELECT count(*) FROM list AS T1 JOIN teachers AS T2 ON T1.classroom = T2.classroom WHERE T1.firstname = "MADLOCK" AND T1.lastname = "RAY" |
List all customer status codes and the number of customers having each status code. | SELECT customer_status_code , count(*) FROM Customers GROUP BY customer_status_code; |
In the 21.40km Santa Rosa 1 Stage, what was the Time? | SELECT time FROM table_name_38 WHERE length = "21.40km" AND name = "santa rosa 1" |
what's the week where attendance is 77,098 | SELECT week FROM table_11406866_2 WHERE attendance = "77,098" |
Find the founder of the company whose name begins with the letter 'S'. | SELECT founder FROM manufacturers WHERE name LIKE 'S%' |
Please list the email adresses of the reviewers who have given the lowest rating to the product HL Mountain Pedal. | SELECT T1.EmailAddress FROM ProductReview AS T1 INNER JOIN Product AS T2 ON T1.ProductID = T2.ProductID WHERE T2.Name = 'HL Mountain Pedal' ORDER BY T1.Rating LIMIT 1 |
Name the least mister international | SELECT MIN(mister_international) FROM table_30007505_1 |
Who was the special guest when the category was vocal groups and the name was Romantic? | SELECT special_guest FROM table_name_28 WHERE category = "vocal groups" AND name = "romantic" |
Give me a list of cities whose temperature in Mar is lower than that in Dec and which have never been host cities. | 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 |
Provide any 5 customers' full names who have rented from Mike Hillyer. | SELECT T3.first_name, T3.last_name FROM staff AS T1 INNER JOIN address AS T2 ON T1.address_id = T2.address_id INNER JOIN customer AS T3 ON T2.address_id = T3.address_id WHERE T1.first_name = 'Mike' AND T1.last_name = 'Hillyer' LIMIT 5 |
What is the highest In service for a vessel with a listed Unit of 12th minesweeper squadron? | SELECT MAX(in_service) FROM table_name_37 WHERE unit = "12th minesweeper squadron" |
Which celebrity who was famous for being the ex busted member and TV presenter exited on day 19? | SELECT celebrity FROM table_name_53 WHERE exited = "day 19" AND famous_for = "ex busted member and tv presenter" |
What is the Place when Steve Pate was the player? | SELECT place FROM table_name_52 WHERE player = "steve pate" |
Who scored 57 points? | SELECT performer FROM table_name_22 WHERE points = 57 |
Show customer ids who don't have an account. | SELECT customer_id FROM Customers EXCEPT SELECT customer_id FROM Accounts |
What are the most goals listed when Jack Trehey was the player, with the listed debut year of 1902, games less than 1? | SELECT MAX(goals) FROM table_name_29 WHERE debut_year = 1902 AND player = "jack trehey" AND games < 1 |
How many points does driver kosuke matsuura have? | SELECT points FROM table_name_17 WHERE driver = "kosuke matsuura" |
What event did Pakistan get the bronze medal at the 1988 Seoul Games? | SELECT event FROM table_name_82 WHERE medal = "bronze" AND games = "1988 seoul" |
What are the id of the games held in London? | SELECT T1.games_id FROM games_city AS T1 INNER JOIN city AS T2 ON T1.city_id = T2.id WHERE T2.city_name = 'London' |
What country is the Eurasia Astana team from? | SELECT country FROM table_name_69 WHERE team = "eurasia astana" |
Who was the home team at the game that had a score of 2 – 2? | SELECT home FROM table_name_96 WHERE score = "2 – 2" |
On Race 14 when the FLap is larger than 1, what is the podium number? | SELECT COUNT(podium) FROM table_name_42 WHERE race = 14 AND flap > 1 |
When the transmission make/type/speed is eaton fs 5306-a manual synchromesh 6 speed, what is the value of the gcm (kg) technical capacity? | SELECT gcm__kg__technical_capacity FROM table_11497980_1 WHERE transmission_make_type_speed = "Eaton FS 5306-A Manual Synchromesh 6 Speed" |
On what circuit was the City of Ipswich 400 race held? | SELECT circuit FROM table_14016079_1 WHERE race_title = "City of Ipswich 400" |
List the names of all the customers with the same payment method as Devin Mills. | SELECT DISTINCT t1.customer_name FROM customers AS t1 JOIN customer_contact_channels AS t2 ON t1.customer_id = t2.customer_id WHERE t1.payment_method = ( SELECT DISTINCT t1.payment_method FROM customers AS t1 JOIN customer_contact_channels AS t2 ON t1.customer_id = t2.customer_id WHERE t1.customer_name = "Devin Mills" ) |
What are the dates and locations of performances? | SELECT Date , LOCATION FROM performance |
How many points for the cooper car company after 1959? | SELECT SUM(points) FROM table_name_90 WHERE entrant = "cooper car company" AND year > 1959 |
Who did the Blue Jays play against on April 11? | SELECT opponent FROM table_name_52 WHERE date = "april 11" |
Can you list the customer names for all the customers that don't have anything listed under the customer_address column? | SELECT customer_name FROM customers WHERE customer_id NOT IN ( SELECT customer_id FROM customer_address_history ) |
How many players weigh more than 90 kg? | SELECT COUNT(T1.ELITEID) FROM PlayerInfo AS T1 INNER JOIN weight_info AS T2 ON T1.weight = T2.weight_id WHERE T2.weight_in_kg > 90 |
Can you show me the names of those journalists ? | Do you mean the journalists from Wales and England who have worked for over a year? | Yes | SELECT name FROM journalist WHERE Nationality = "Wales" and years_working > 1 UNION SELECT name FROM journalist WHERE Nationality = "England" and years_working > 1 |
Please list the actor IDs whose movies have the newest published date. | SELECT T1.actorid FROM movies2actors AS T1 INNER JOIN movies AS T2 ON T1.movieid = T2.movieid WHERE T2.year = 4 |
What are the names and descriptions for all the sections? | SELECT section_name , section_description FROM Sections |
List the urls for all the "fiction-science-fiction" podcasts. | SELECT itunes_url FROM podcasts WHERE podcast_id IN ( SELECT podcast_id FROM categories WHERE category = 'fiction-science-fiction' ) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.