answer stringlengths 6 3.91k | question stringlengths 7 766 | context stringlengths 27 7.14k |
|---|---|---|
SELECT AVG(rating), languages FROM song GROUP BY languages | What is the average rating of songs for each language? | CREATE TABLE song (languages VARCHAR, rating INTEGER) |
SELECT agency FROM table_name_32 WHERE birthday = "1998.11.09" | What's the agency of the member born on 1998.11.09? | CREATE TABLE table_name_32 (
agency VARCHAR,
birthday VARCHAR
) |
SELECT COUNT(citrate) FROM table_16083989_1 WHERE species = "Salmonella spp." | What is the result for salmonella spp. if you use citrate? | CREATE TABLE table_16083989_1 (citrate VARCHAR, species VARCHAR) |
SELECT T1.gender, T1.artist_name FROM artist AS T1 JOIN song AS T2 ON T1.artist_name = T2.artist_name ORDER BY T2.resolution LIMIT 1 | Return the gender and name of artist who produced the song with the lowest resolution. | CREATE TABLE artist (gender VARCHAR, artist_name VARCHAR); CREATE TABLE song (artist_name VARCHAR, resolution VARCHAR) |
SELECT SUM(losses) FROM table_name_6 WHERE wins > 6 AND club = "camperdown" AND against > 1238 | What is the sum of losses when wins is more than 6, club is camperdown and against is more than 1238? | CREATE TABLE table_name_6 (
losses INTEGER,
against VARCHAR,
wins VARCHAR,
club VARCHAR
) |
SELECT species FROM table_16083989_1 WHERE voges_proskauer = "Negative" AND indole = "Negative" | Which species show a negative result with both voges-proskauer and indole? | CREATE TABLE table_16083989_1 (species VARCHAR, voges_proskauer VARCHAR, indole VARCHAR) |
SELECT COUNT(*), formats FROM files GROUP BY formats | For each file format, return the number of artists who released songs in that format. | CREATE TABLE files (formats VARCHAR) |
SELECT COUNT(pictorials) FROM table_1566848_7 WHERE centerfold_model = "Rebekka Armstrong" | Who were all the pictorials when the centerfold model was Rebekka Armstrong? | CREATE TABLE table_1566848_7 (
pictorials VARCHAR,
centerfold_model VARCHAR
) |
SELECT voges_proskauer FROM table_16083989_1 WHERE citrate = "Positive" | What are the results for testing the species with voges-proskauer when citrate yields a positive result? | CREATE TABLE table_16083989_1 (voges_proskauer VARCHAR, citrate VARCHAR) |
SELECT DISTINCT song_name FROM song WHERE resolution > (SELECT MIN(resolution) FROM song WHERE languages = "english") | Find the distinct names of all songs that have a higher resolution than some songs in English. | CREATE TABLE song (song_name VARCHAR, resolution INTEGER, languages VARCHAR) |
SELECT period FROM table_name_90 WHERE country = "south korea" AND peak_position = "#1" | Name the period for south korea with peak position of #1 | CREATE TABLE table_name_90 (
period VARCHAR,
country VARCHAR,
peak_position VARCHAR
) |
SELECT indole FROM table_16083989_1 WHERE species = "Proteus mirabilis" | What is the result of proteus mirabilis tested with indole? | CREATE TABLE table_16083989_1 (indole VARCHAR, species VARCHAR) |
SELECT song_name FROM song WHERE rating < (SELECT MAX(rating) FROM song WHERE genre_is = "blues") | What are the names of all songs that have a lower rating than some song of blues genre? | CREATE TABLE song (song_name VARCHAR, rating INTEGER, genre_is VARCHAR) |
SELECT "Week 4" FROM table_12982 WHERE "Week 2" = 'samantha speer' | What Week 4 has a Week 2 of samantha speer? | CREATE TABLE table_12982 (
"Week 1" text,
"Week 2" text,
"Week 3" text,
"Week 4" text,
"Week 5" text
) |
SELECT originalairdate FROM table_16090262_1 WHERE tv_broadcast = "S07E04" | When was the show originally aired that had a TV broadcast of S07E04? | CREATE TABLE table_16090262_1 (originalairdate VARCHAR, tv_broadcast VARCHAR) |
SELECT T1.artist_name, T1.country FROM artist AS T1 JOIN song AS T2 ON T1.artist_name = T2.artist_name WHERE T2.song_name LIKE "%love%" | What is the name and country of origin of the artist who released a song that has "love" in its title? | CREATE TABLE song (artist_name VARCHAR, song_name VARCHAR); CREATE TABLE artist (artist_name VARCHAR, country VARCHAR) |
SELECT DISTINCT course.number FROM course INNER JOIN program_course ON program_course.course_id = course.course_id WHERE (course.number = 487 OR course.number = 521) AND program_course.workload = (SELECT MIN(PROGRAM_COURSEalias1.workload) FROM program_course AS PROGRAM_COURSEalias1 INNER JOIN course AS COURSEalias1 ON ... | EECS 487 and EECS 521 , which one is easier ? | CREATE TABLE student (
student_id int,
lastname varchar,
firstname varchar,
program_id int,
declare_major varchar,
total_credit int,
total_gpa float,
entered_as varchar,
admit_term int,
predicted_graduation_semester int,
degree varchar,
minor varchar,
internship varch... |
SELECT title FROM table_16090262_1 WHERE no_in_season = 4 | Which title was No. 4 in season? | CREATE TABLE table_16090262_1 (title VARCHAR, no_in_season VARCHAR) |
SELECT T1.artist_name, T1.gender FROM artist AS T1 JOIN song AS T2 ON T1.artist_name = T2.artist_name WHERE T2.releasedate LIKE "%Mar%" | List the name and gender for all artists who released songs in March. | CREATE TABLE song (artist_name VARCHAR, releasedate VARCHAR); CREATE TABLE artist (artist_name VARCHAR, gender VARCHAR) |
SELECT "Copa Libertadores 1996" FROM table_38605 WHERE "Supercopa 1995" = 'round 1' AND "Team" = 'argentinos juniors' | which Copa Libertadores 1996 has round 1 Supercopa 1995 and argentinos juniors team ? | CREATE TABLE table_38605 (
"Team" text,
"Recopa 1995" text,
"Supercopa 1995" text,
"CONMEBOL 1995" text,
"Copa Libertadores 1996" text
) |
SELECT directed_by FROM table_16090262_1 WHERE tv_broadcast = "S07E04" | Who directed the show that had a TV broadcast of S07E04? | CREATE TABLE table_16090262_1 (directed_by VARCHAR, tv_broadcast VARCHAR) |
SELECT g_name, rating FROM genre ORDER BY g_name | List the names of all genres in alphabetical oder, together with its ratings. | CREATE TABLE genre (g_name VARCHAR, rating VARCHAR) |
SELECT "Date" FROM table_67107 WHERE "Visiting Team" = 'denver broncos' | Name the date for visiting team of denver broncos | CREATE TABLE table_67107 (
"Date" text,
"Visiting Team" text,
"Final Score" text,
"Host Team" text,
"Stadium" text
) |
SELECT mid_atlantic_south__washington, _dc_ FROM table_16105186_2 WHERE alaska___juneau__ = "90 g/mi (56 g/km)" AND california__san_francisco_ = "110 g/mi (68 g/km)" | What was the emission rating in Mid-Atlantic South for the vehicle that was rated 90 g/mi (56 g/km) in Alaska and 110 g/mi (68 g/km) in California? | CREATE TABLE table_16105186_2 (mid_atlantic_south__washington VARCHAR, _dc_ VARCHAR, alaska___juneau__ VARCHAR, california__san_francisco_ VARCHAR) |
SELECT song_name FROM song ORDER BY resolution | Give me a list of the names of all songs ordered by their resolution. | CREATE TABLE song (song_name VARCHAR, resolution VARCHAR) |
SELECT COUNT("Game") FROM table_7818 WHERE "Team" = 'charlotte' | What was the game number of the game played against Charlotte? | CREATE TABLE table_7818 (
"Game" real,
"Date" text,
"Team" text,
"Score" text,
"High points" text,
"High rebounds" text,
"High assists" text,
"Location Attendance" text,
"Record" text
) |
SELECT mid_atlantic_south__washington, _dc_ FROM table_16105186_2 WHERE midwest__des_moines_ = "300 g/mi (186 g/km)" | What was the emission rating in Mid-Atlantic South for the vehicle that was rated 300 g/mi (186 g/km) in the Midwest? | CREATE TABLE table_16105186_2 (mid_atlantic_south__washington VARCHAR, _dc_ VARCHAR, midwest__des_moines_ VARCHAR) |
SELECT f_id FROM files WHERE formats = "mp4" UNION SELECT f_id FROM song WHERE resolution > 720 | What are the ids of songs that are available in either mp4 format or have resolution above 720? | CREATE TABLE song (f_id VARCHAR, formats VARCHAR, resolution INTEGER); CREATE TABLE files (f_id VARCHAR, formats VARCHAR, resolution INTEGER) |
SELECT JOB_TITLE, COUNT(JOB_TITLE) FROM employees AS T1 JOIN jobs AS T2 ON T1.JOB_ID = T2.JOB_ID WHERE T1.DEPARTMENT_ID = 80 GROUP BY JOB_TITLE | Compare the total number of different job titles for all those jobs in department 80 using a bar chart. | CREATE TABLE employees (
EMPLOYEE_ID decimal(6,0),
FIRST_NAME varchar(20),
LAST_NAME varchar(25),
EMAIL varchar(25),
PHONE_NUMBER varchar(20),
HIRE_DATE date,
JOB_ID varchar(10),
SALARY decimal(8,2),
COMMISSION_PCT decimal(2,2),
MANAGER_ID decimal(6,0),
DEPARTMENT_ID decimal(... |
SELECT us_national_average_electric_mix FROM table_16105186_2 WHERE midwest__des_moines_ = "280 g/mi (174 g/km)" | What was the US national average electric mix rating for the vehicle that was rated 280 g/mi (174 g/km) in the Midwest? | CREATE TABLE table_16105186_2 (us_national_average_electric_mix VARCHAR, midwest__des_moines_ VARCHAR) |
SELECT T2.song_name FROM files AS T1 JOIN song AS T2 ON T1.f_id = T2.f_id WHERE T1.duration LIKE "4:%" UNION SELECT song_name FROM song WHERE languages = "english" | List the names of all songs that have 4 minute duration or are in English. | CREATE TABLE files (f_id VARCHAR, duration VARCHAR); CREATE TABLE song (song_name VARCHAR, f_id VARCHAR); CREATE TABLE song (song_name VARCHAR, languages VARCHAR) |
SELECT "Score" FROM table_9624 WHERE "Country" = 'united states' AND "Player" = 'fuzzy zoeller' | What was Fuzzy Zoeller's score in the United States? | CREATE TABLE table_9624 (
"Place" text,
"Player" text,
"Country" text,
"Score" text,
"To par" text
) |
SELECT COUNT(california__san_francisco_) FROM table_16105186_2 WHERE vehicle = "Ford Focus Electric" | How many Ford Focus electric vehicle emission test scores were recorded in California? | CREATE TABLE table_16105186_2 (california__san_francisco_ VARCHAR, vehicle VARCHAR) |
SELECT languages FROM song GROUP BY languages ORDER BY COUNT(*) DESC LIMIT 1 | What is the language used most often in the songs? | CREATE TABLE song (languages VARCHAR) |
SELECT COUNT("film") FROM table_203_79 WHERE "year" = 1978 | what is the number of live action american superhero movies released in 1978 ? | CREATE TABLE table_203_79 (
id number,
"year" number,
"film" text,
"publisher" text,
"director" text,
"distributor" text,
"worldwide gross" text,
"notes" text
) |
SELECT california__san_francisco_ FROM table_16105186_2 WHERE alaska___juneau__ = "80 g/mi (50 g/km)" AND southeast__atlanta_ = "250 g/mi (155 g/km)" | What was the emission rating in California for the vehicle that was rated 80 g/mi (50 g/km) in Alaska and 250 g/mi (155 g/km) in the Southeast ? | CREATE TABLE table_16105186_2 (california__san_francisco_ VARCHAR, alaska___juneau__ VARCHAR, southeast__atlanta_ VARCHAR) |
SELECT artist_name FROM song WHERE resolution > 500 GROUP BY languages ORDER BY COUNT(*) DESC LIMIT 1 | What is the language that was used most often in songs with resolution above 500? | CREATE TABLE song (artist_name VARCHAR, languages VARCHAR, resolution INTEGER) |
SELECT t3.drug FROM (SELECT t2.drug, DENSE_RANK() OVER (ORDER BY COUNT(*) DESC) AS c1 FROM (SELECT admissions.subject_id, prescriptions.startdate FROM prescriptions JOIN admissions ON prescriptions.hadm_id = admissions.hadm_id WHERE prescriptions.drug = 'rufinamide' AND STRFTIME('%y', prescriptions.startdate) <= '2101'... | what are the four most common medicines that patients were prescribed during the same month after they were prescribed rufinamide until 2101? | CREATE TABLE d_items (
row_id number,
itemid number,
label text,
linksto text
)
CREATE TABLE d_icd_diagnoses (
row_id number,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE patients (
row_id number,
subject_id number,
gender text,
dob time,
dod tim... |
SELECT MIN(attendance) FROM table_16119656_1 | What was the lowest no. of attendance on record? | CREATE TABLE table_16119656_1 (attendance INTEGER) |
SELECT artist_name FROM artist WHERE country = "UK" AND gender = "Male" | What are the names of artists who are Male and are from UK? | CREATE TABLE artist (artist_name VARCHAR, country VARCHAR, gender VARCHAR) |
SELECT COUNT(timeslot) FROM table_19834691_4 WHERE _number = 1 | name the total number of timeslot for number 1 | CREATE TABLE table_19834691_4 (
timeslot VARCHAR,
_number VARCHAR
) |
SELECT date FROM table_16119656_1 WHERE attendance < 6427.0 | When was the game played if the attendance is less than 6427.0? | CREATE TABLE table_16119656_1 (date VARCHAR, attendance INTEGER) |
SELECT song_name FROM song WHERE genre_is = "modern" OR languages = "english" | Find the names of songs whose genre is modern or language is English. | CREATE TABLE song (song_name VARCHAR, genre_is VARCHAR, languages VARCHAR) |
SELECT MIN(bronze) FROM table_name_66 WHERE total = 4 AND gold < 1 | What is the low bronze total for the team with 4 total and under 1 gold? | CREATE TABLE table_name_66 (
bronze INTEGER,
total VARCHAR,
gold VARCHAR
) |
SELECT attendance FROM table_16119656_1 WHERE date = "January 9, 1988" | How many were in attendance during the game on January 9, 1988? | CREATE TABLE table_16119656_1 (attendance VARCHAR, date VARCHAR) |
SELECT T2.song_name FROM files AS T1 JOIN song AS T2 ON T1.f_id = T2.f_id WHERE T1.formats = "mp3" INTERSECT SELECT song_name FROM song WHERE resolution < 1000 | Return the names of songs for which format is mp3 and resolution is below 1000. | CREATE TABLE song (song_name VARCHAR, resolution INTEGER); CREATE TABLE song (song_name VARCHAR, f_id VARCHAR); CREATE TABLE files (f_id VARCHAR, formats VARCHAR) |
SELECT dept_name, MIN(salary) FROM instructor GROUP BY dept_name ORDER BY dept_name | Bar chart of minimal salary from each dept name, order dept_name in ascending order please. | CREATE TABLE instructor (
ID varchar(5),
name varchar(20),
dept_name varchar(20),
salary numeric(8,2)
)
CREATE TABLE prereq (
course_id varchar(8),
prereq_id varchar(8)
)
CREATE TABLE student (
ID varchar(5),
name varchar(20),
dept_name varchar(20),
tot_cred numeric(3,0)
)
CRE... |
SELECT headquarters FROM table_1610301_1 WHERE code = "HY" | Where is the headquarters of the place whose abbreviation is hy? | CREATE TABLE table_1610301_1 (headquarters VARCHAR, code VARCHAR) |
SELECT artist_name FROM artist WHERE country = "UK" INTERSECT SELECT T1.artist_name FROM artist AS T1 JOIN song AS T2 ON T1.artist_name = T2.artist_name WHERE T2.languages = "english" | Return the names of singers who are from UK and released an English song. | CREATE TABLE song (artist_name VARCHAR, languages VARCHAR); CREATE TABLE artist (artist_name VARCHAR); CREATE TABLE artist (artist_name VARCHAR, country VARCHAR) |
SELECT "Segment B" FROM table_35545 WHERE "Netflix" = 's03e01' | What was the B segmint for Netlix S03E01? | CREATE TABLE table_35545 (
"Series Ep." text,
"Episode" real,
"Netflix" text,
"Segment A" text,
"Segment B" text,
"Segment C" text,
"Segment D" text
) |
SELECT headquarters FROM table_1610301_1 WHERE population__2011_ = 3811738 | Where is the headquarters of the place whose population in 2011 was 3811738? | CREATE TABLE table_1610301_1 (headquarters VARCHAR, population__2011_ VARCHAR) |
SELECT AVG(rating), AVG(resolution) FROM song WHERE languages = "bangla" | What are the average rating and resolution of songs that are in Bangla? | CREATE TABLE song (rating INTEGER, resolution INTEGER, languages VARCHAR) |
SELECT DISTINCT ground_service.transport_type FROM city, ground_service WHERE city.city_name = 'ATLANTA' AND ground_service.city_code = city.city_code | in ATLANTA i would like information on ground transportation | CREATE TABLE flight_leg (
flight_id int,
leg_number int,
leg_flight int
)
CREATE TABLE fare (
fare_id int,
from_airport varchar,
to_airport varchar,
fare_basis_code text,
fare_airline text,
restriction_code text,
one_direction_cost int,
round_trip_cost int,
round_trip_re... |
SELECT MIN(population__2011_) FROM table_1610301_1 WHERE district = "Prakasam" | What was the minimum population in 2011 of the district of Prakasam? | CREATE TABLE table_1610301_1 (population__2011_ INTEGER, district VARCHAR) |
SELECT MAX(T2.resolution), MIN(T2.resolution) FROM files AS T1 JOIN song AS T2 ON T1.f_id = T2.f_id WHERE T1.duration LIKE "3:%" | What are the maximum and minimum resolution of songs whose duration is 3 minutes? | CREATE TABLE files (f_id VARCHAR, duration VARCHAR); CREATE TABLE song (resolution INTEGER, f_id VARCHAR) |
SELECT SUBSTRING(Body, CHARINDEX(@stEnd, Body) + LEN(@stStart) - (CHARINDEX(REVERSE(@stStart), REVERSE(LEFT(Body, CHARINDEX(@stEnd, Body) + LEN(@stStart) - 1))) + LEN(@stStart) - 1), CHARINDEX(REVERSE(@stStart), REVERSE(LEFT(Body, CHARINDEX(@stEnd, Body) + LEN(@stStart) - 1))) + LEN(@stStart) - 1) AS "gif_url", CASE WH... | GENERATE HTML PAGE SHOWING (mostly) ANIMATED GIFS posted in specified # of days. Creates HTML to paste into blank .html file showing .GIF images (mostly animated GIFs) linked to Q&A posts within 'the past number of days specified'. Looks for the first occurrence of `.gif` in the post body and searches backwards for `ht... | CREATE TABLE CloseAsOffTopicReasonTypes (
Id number,
IsUniversal boolean,
InputTitle text,
MarkdownInputGuidance text,
MarkdownPostOwnerGuidance text,
MarkdownPrivilegedUserGuidance text,
MarkdownConcensusDescription text,
CreationDate time,
CreationModeratorId number,
ApprovalDa... |
SELECT code FROM table_1610301_1 WHERE district = "Mahbubnagar" | What is the abbreviation of the district of Mahbubnagar? | CREATE TABLE table_1610301_1 (code VARCHAR, district VARCHAR) |
SELECT MAX(T1.duration), MAX(T2.resolution), T2.languages FROM files AS T1 JOIN song AS T2 ON T1.f_id = T2.f_id GROUP BY T2.languages ORDER BY T2.languages | What are the maximum duration and resolution of songs grouped and ordered by languages? | CREATE TABLE song (languages VARCHAR, resolution INTEGER, f_id VARCHAR); CREATE TABLE files (duration INTEGER, f_id VARCHAR) |
SELECT "Arranger(s)" FROM table_76990 WHERE "Title" = 'ขอโทษ' | Who was the arranger of ' '? | CREATE TABLE table_76990 (
"Title" text,
"Lyricist(s)" text,
"Composer(s)" text,
"Arranger(s)" text,
"Length" text
) |
SELECT population__2011_ FROM table_1610301_1 WHERE district = "East Godavari" | What is the 2011 population of the district of East Godavari? | CREATE TABLE table_1610301_1 (population__2011_ VARCHAR, district VARCHAR) |
SELECT MIN(T1.duration), MIN(T2.rating), T2.genre_is FROM files AS T1 JOIN song AS T2 ON T1.f_id = T2.f_id GROUP BY T2.genre_is ORDER BY T2.genre_is | What are the shortest duration and lowest rating of songs grouped by genre and ordered by genre? | CREATE TABLE song (genre_is VARCHAR, rating INTEGER, f_id VARCHAR); CREATE TABLE files (duration INTEGER, f_id VARCHAR) |
SELECT MAX("Seats") FROM table_52371 WHERE "Votes" = '244,867' | Which highest number of Seats has votes of 244,867? | CREATE TABLE table_52371 (
"Party" text,
"Leader" text,
"Votes" real,
"Percentage" text,
"Seats" real
) |
SELECT gdp_adjusted__$_billions_ FROM table_1610496_3 WHERE gdp_per_capita_nominal__$_ = 2874 | What is the adjusted GDP when the nominal GDP per capita is 2874? | CREATE TABLE table_1610496_3 (gdp_adjusted__$_billions_ VARCHAR, gdp_per_capita_nominal__$_ VARCHAR) |
SELECT T1.artist_name, COUNT(*) FROM artist AS T1 JOIN song AS T2 ON T1.artist_name = T2.artist_name WHERE T2.languages = "english" GROUP BY T2.artist_name HAVING COUNT(*) >= 1 | Find the names and number of works of all artists who have at least one English songs. | CREATE TABLE song (artist_name VARCHAR, languages VARCHAR); CREATE TABLE artist (artist_name VARCHAR) |
SELECT "Date" FROM table_62049 WHERE "Venue" = 'home' AND "Opponent" = 'peterborough phantoms' | When did the peterborough phantoms play at a venue of home? | CREATE TABLE table_62049 (
"Date" text,
"Opponent" text,
"Venue" text,
"Result" text,
"Competition" text
) |
SELECT gdp_per_capita_adjusted__$_ FROM table_1610496_3 WHERE population__millions_ = "37.376" | What is the adjusted GDP per capita when the population is 37.376 million? | CREATE TABLE table_1610496_3 (gdp_per_capita_adjusted__$_ VARCHAR, population__millions_ VARCHAR) |
SELECT T1.artist_name, T1.country FROM artist AS T1 JOIN song AS T2 ON T1.artist_name = T2.artist_name WHERE T2.resolution > 900 GROUP BY T2.artist_name HAVING COUNT(*) >= 1 | Find the name and country of origin for all artists who have release at least one song of resolution above 900. | CREATE TABLE song (artist_name VARCHAR, resolution INTEGER); CREATE TABLE artist (artist_name VARCHAR, country VARCHAR) |
SELECT COUNT(*), T1.blockfloor FROM block AS T1 JOIN room AS T2 ON T1.blockfloor = T2.blockfloor AND T1.blockcode = T2.blockcode GROUP BY T1.blockfloor | How many rooms does each block floor have? | CREATE TABLE patient (
ssn number,
name text,
address text,
phone text,
insuranceid number,
pcp number
)
CREATE TABLE medication (
code number,
name text,
brand text,
description text
)
CREATE TABLE prescribes (
physician number,
patient number,
medication number,
... |
SELECT MIN(gdp_per_capita_nominal__) AS $_ FROM table_1610496_3 WHERE population__millions_ = "63.056" | What is the nominal GDP per capita when the population is 63.056 million? | CREATE TABLE table_1610496_3 (gdp_per_capita_nominal__ INTEGER, population__millions_ VARCHAR) |
SELECT T1.artist_name, COUNT(*) FROM artist AS T1 JOIN song AS T2 ON T1.artist_name = T2.artist_name GROUP BY T2.artist_name ORDER BY COUNT(*) DESC LIMIT 3 | Find the names and number of works of the three artists who have produced the most songs. | CREATE TABLE song (artist_name VARCHAR); CREATE TABLE artist (artist_name VARCHAR) |
SELECT DISTINCT course_offering.end_time, course_offering.friday, course_offering.monday, course_offering.saturday, course_offering.start_time, course_offering.sunday, course_offering.thursday, course_offering.tuesday, course_offering.wednesday FROM course, course_offering, semester WHERE course.course_id = course_offe... | When is 511 offered next semester ? | CREATE TABLE course_tags_count (
course_id int,
clear_grading int,
pop_quiz int,
group_projects int,
inspirational int,
long_lectures int,
extra_credit int,
few_tests int,
good_feedback int,
tough_tests int,
heavy_papers int,
cares_for_students int,
heavy_assignments ... |
SELECT gdp_adjusted__$_billions_ FROM table_1610496_3 WHERE population__millions_ = "5.141" | What is the adjusted GDP when the population is 5.141 million? | CREATE TABLE table_1610496_3 (gdp_adjusted__$_billions_ VARCHAR, population__millions_ VARCHAR) |
SELECT T1.country FROM artist AS T1 JOIN song AS T2 ON T1.artist_name = T2.artist_name GROUP BY T2.artist_name ORDER BY COUNT(*) LIMIT 1 | Find the country of origin for the artist who made the least number of songs? | CREATE TABLE song (artist_name VARCHAR); CREATE TABLE artist (country VARCHAR, artist_name VARCHAR) |
SELECT prohibition_ticket FROM table_name_14 WHERE progressive_ticket = "eugene m. travis" | What name ran for the Prohibition ticket when the Progressive ticket was Eugene M. Travis? | CREATE TABLE table_name_14 (
prohibition_ticket VARCHAR,
progressive_ticket VARCHAR
) |
SELECT population__millions_ FROM table_1610496_3 WHERE gdp_adjusted__$_billions_ = "492" | What is the population in millions when the adjusted GDP is 492 billion? | CREATE TABLE table_1610496_3 (population__millions_ VARCHAR, gdp_adjusted__$_billions_ VARCHAR) |
SELECT song_name FROM song WHERE rating < (SELECT MIN(rating) FROM song WHERE languages = 'english') | What are the names of the songs whose rating is below the rating of all songs in English? | CREATE TABLE song (song_name VARCHAR, rating INTEGER, languages VARCHAR) |
SELECT proto_oceanic FROM table_name_48 WHERE proto_polynesian = "*lima" | Which Proto-Oceanic has a Proto-Polynesian of *lima? | CREATE TABLE table_name_48 (
proto_oceanic VARCHAR,
proto_polynesian VARCHAR
) |
SELECT gdp_adjusted__$_billions_ FROM table_1610496_3 WHERE gdp_nominal__$_billions_ = "8.43" | What is the adjusted GDP when the nominal GDP is 8.43 (in billions)? | CREATE TABLE table_1610496_3 (gdp_adjusted__$_billions_ VARCHAR, gdp_nominal__$_billions_ VARCHAR) |
SELECT f_id FROM song WHERE resolution > (SELECT MAX(resolution) FROM song WHERE rating < 8) | What is ids of the songs whose resolution is higher than the resolution of any songs with rating lower than 8? | CREATE TABLE song (f_id VARCHAR, resolution INTEGER, rating INTEGER) |
SELECT AVG("Drawn") FROM table_41538 WHERE "Difference" = '17' AND "Points" = '22' | What is the average number of drawn with a difference of 17 and 22 points? | CREATE TABLE table_41538 (
"Position" real,
"Team" text,
"Points" real,
"Played" real,
"Drawn" real,
"Lost" real,
"Against" real,
"Difference" text
) |
SELECT operating_profit__s$m_ FROM table_161591_2 WHERE expenditure__s$m_ = "12,127.8" | What was the opearint profit (s$m) associated with an expenditure (s$m) of 12,127.8? | CREATE TABLE table_161591_2 (operating_profit__s$m_ VARCHAR, expenditure__s$m_ VARCHAR) |
SELECT f_id FROM song WHERE resolution > (SELECT AVG(resolution) FROM song WHERE genre_is = "modern") | What is ids of the songs whose resolution is higher than the average resolution of songs in modern genre? | CREATE TABLE song (f_id VARCHAR, resolution INTEGER, genre_is VARCHAR) |
SELECT diagnosis.diagnosisname FROM diagnosis WHERE diagnosis.patientunitstayid IN (SELECT patient.patientunitstayid FROM patient WHERE patient.patienthealthsystemstayid IN (SELECT patient.patienthealthsystemstayid FROM patient WHERE patient.uniquepid = '015-7988')) AND DATETIME(diagnosis.diagnosistime) <= DATETIME(CUR... | what is patient 015-7988's first diagnosis until 4 years ago? | CREATE TABLE intakeoutput (
intakeoutputid number,
patientunitstayid number,
cellpath text,
celllabel text,
cellvaluenumeric number,
intakeoutputtime time
)
CREATE TABLE medication (
medicationid number,
patientunitstayid number,
drugname text,
dosage text,
routeadmin text,
... |
SELECT expenditure__s$m_ FROM table_161591_2 WHERE operating_profit__s$m_ = "717.1" | What was the expenditure (s$m) associated with an operating profit (s$m) of 717.1? | CREATE TABLE table_161591_2 (expenditure__s$m_ VARCHAR, operating_profit__s$m_ VARCHAR) |
SELECT T1.artist_name FROM artist AS T1 JOIN song AS T2 ON T1.artist_name = T2.artist_name WHERE T2.languages = "bangla" GROUP BY T2.artist_name ORDER BY COUNT(*) DESC LIMIT 3 | Find the top 3 artists who have the largest number of songs works whose language is Bangla. | CREATE TABLE song (artist_name VARCHAR, languages VARCHAR); CREATE TABLE artist (artist_name VARCHAR) |
SELECT "Species Specific" FROM table_36079 WHERE "Comparative" = 'no' AND "Intra-molecular structure" = 'no' AND "Link" = 'sourcecode' | Which Species Specific has a Comparative of no, and an Intra-molecular structure of no, and a Link of sourcecode? | CREATE TABLE table_36079 (
"Name" text,
"Species Specific" text,
"Intra-molecular structure" text,
"Comparative" text,
"Link" text
) |
SELECT COUNT(profit_before_taxation__s) AS $m_ FROM table_161591_2 WHERE operating_profit__s$m_ = "717.1" | How many years was the operating profit (s$m) 717.1? | CREATE TABLE table_161591_2 (profit_before_taxation__s VARCHAR, operating_profit__s$m_ VARCHAR) |
SELECT f_id, genre_is, artist_name FROM song WHERE languages = "english" ORDER BY rating | List the id, genre and artist name of English songs ordered by rating. | CREATE TABLE song (f_id VARCHAR, genre_is VARCHAR, artist_name VARCHAR, languages VARCHAR, rating VARCHAR) |
SELECT MIN("Overall") FROM table_70973 WHERE "Round" > '17' | What is the lowest overall with more than 17 rounds? | CREATE TABLE table_70973 (
"Round" real,
"Overall" real,
"Player" text,
"Position" text,
"College" text
) |
SELECT simplified_characters FROM table_16162581_1 WHERE wade_giles = "ch'ing-yüan … i-ma" | Name the simplified characters for wade giles is ch'ing-yüan … i-ma | CREATE TABLE table_16162581_1 (simplified_characters VARCHAR, wade_giles VARCHAR) |
SELECT T1.duration, T1.file_size, T1.formats FROM files AS T1 JOIN song AS T2 ON T1.f_id = T2.f_id WHERE T2.genre_is = "pop" ORDER BY T2.song_name | List the duration, file size and format of songs whose genre is pop, ordered by title? | CREATE TABLE song (f_id VARCHAR, genre_is VARCHAR, song_name VARCHAR); CREATE TABLE files (duration VARCHAR, file_size VARCHAR, formats VARCHAR, f_id VARCHAR) |
SELECT admissions.marital_status FROM admissions WHERE admissions.subject_id = 19894 AND NOT admissions.dischtime IS NULL ORDER BY admissions.admittime LIMIT 1 | what is the marital status of patient 19894 in their first hospital encounter. | CREATE TABLE procedures_icd (
row_id number,
subject_id number,
hadm_id number,
icd9_code text,
charttime time
)
CREATE TABLE admissions (
row_id number,
subject_id number,
hadm_id number,
admittime time,
dischtime time,
admission_type text,
admission_location text,
... |
SELECT pinyin FROM table_16162581_1 WHERE date__ce_ = "657" | Name the pinyin for 657 date | CREATE TABLE table_16162581_1 (pinyin VARCHAR, date__ce_ VARCHAR) |
SELECT DISTINCT artist_name FROM song WHERE languages = "english" EXCEPT SELECT DISTINCT artist_name FROM song WHERE rating > 8 | Find the names of the artists who have produced English songs but have never received rating higher than 8. | CREATE TABLE song (artist_name VARCHAR, languages VARCHAR, rating INTEGER) |
SELECT labevents.charttime FROM labevents WHERE labevents.itemid IN (SELECT d_labitems.itemid FROM d_labitems WHERE d_labitems.label = 'white blood cells') AND labevents.hadm_id IN (SELECT admissions.hadm_id FROM admissions WHERE admissions.subject_id = 92788 AND admissions.dischtime IS NULL) ORDER BY labevents.chartti... | when did patient 92788 get white blood cells lab test for the last time during their current hospital visit? | CREATE TABLE d_labitems (
row_id number,
itemid number,
label text
)
CREATE TABLE admissions (
row_id number,
subject_id number,
hadm_id number,
admittime time,
dischtime time,
admission_type text,
admission_location text,
discharge_location text,
insurance text,
lan... |
SELECT text FROM table_16162581_1 WHERE simplified_characters = "心猿意马" | Name the text for 心猿意马 | CREATE TABLE table_16162581_1 (text VARCHAR, simplified_characters VARCHAR) |
SELECT DISTINCT artist_name FROM artist WHERE country = "Bangladesh" EXCEPT SELECT DISTINCT artist_name FROM song WHERE rating > 7 | Find the names of the artists who are from Bangladesh and have never received rating higher than 7. | CREATE TABLE artist (artist_name VARCHAR, country VARCHAR, rating INTEGER); CREATE TABLE song (artist_name VARCHAR, country VARCHAR, rating INTEGER) |
SELECT name, COUNT(name) FROM constructors AS T1 JOIN constructorStandings AS T2 ON T1.constructorId = T2.constructorId WHERE T1.nationality = "Japanese" AND T2.points > 5 GROUP BY name ORDER BY name | What are the number of the names of all the Japanese constructors that have earned more than 5 points?, display in ascending by the x-axis please. | CREATE TABLE drivers (
driverId INTEGER,
driverRef TEXT,
number TEXT,
code TEXT,
forename TEXT,
surname TEXT,
dob TEXT,
nationality TEXT,
url TEXT
)
CREATE TABLE pitStops (
raceId INTEGER,
driverId INTEGER,
stop INTEGER,
lap INTEGER,
time TEXT,
duration TEXT,... |
SELECT simplified_characters FROM table_16162581_1 WHERE wade_giles = "hsin-yüan … i-ma" | Name the simplified charaacters being hsin-yüan … i-ma | CREATE TABLE table_16162581_1 (simplified_characters VARCHAR, wade_giles VARCHAR) |
SELECT T1.name_full, T1.college_id FROM college AS T1 JOIN player_college AS T2 ON T1.college_id = T2.college_id GROUP BY T1.college_id ORDER BY COUNT(*) DESC LIMIT 1 | what is the full name and id of the college with the largest number of baseball players? | CREATE TABLE player_college (college_id VARCHAR); CREATE TABLE college (name_full VARCHAR, college_id VARCHAR) |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.