instruction stringlengths 0 1.06k | input stringlengths 33 7.14k | response stringlengths 2 4.44k | source stringclasses 25 values | prompt listlengths 1 1 | input_ids listlengths 1 1 | label_ids listlengths 1 1 |
|---|---|---|---|---|---|---|
Name the home team for carlton away team | CREATE TABLE table_name_77 (
home_team VARCHAR,
away_team VARCHAR
) | SELECT home_team FROM table_name_77 WHERE away_team = "carlton" | sql_create_context | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
what will the population of Asia be when Latin America/Caribbean is 783 (7.5%)? | CREATE TABLE table_22767 (
"Year" real,
"World" real,
"Asia" text,
"Africa" text,
"Europe" text,
"Latin America/Caribbean" text,
"Northern America" text,
"Oceania" text
) | SELECT "Asia" FROM table_22767 WHERE "Latin America/Caribbean" = '783 (7.5%)' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
How many faculty members do we have for each gender? Draw a bar chart, order by the Y-axis in descending. | CREATE TABLE Student (
StuID INTEGER,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE TABLE Faculty (
FacID INTEGER,
Lname VARCHAR(15),
Fname VARCHAR(15),
Rank VARCHAR(15),
Sex VARCHAR(1),
Phone INTEGER,
Room VARCHAR(5),
Building VARCHAR(13)
)
CREATE TABLE Faculty_Participates_in (
FacID INTEGER,
actid INTEGER
)
CREATE TABLE Activity (
actid INTEGER,
activity_name varchar(25)
)
CREATE TABLE Participates_in (
stuid INTEGER,
actid INTEGER
) | SELECT Sex, COUNT(*) FROM Faculty GROUP BY Sex ORDER BY COUNT(*) DESC | nvbench | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
List the record of 0-1 from the table? | CREATE TABLE table_14656147_2 (
week VARCHAR,
record VARCHAR
) | SELECT week FROM table_14656147_2 WHERE record = "0-1" | sql_create_context | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Which silver has a Gold smaller than 12, a Rank smaller than 5, and a Bronze of 5? | CREATE TABLE table_name_24 (
silver VARCHAR,
bronze VARCHAR,
gold VARCHAR,
rank VARCHAR
) | SELECT silver FROM table_name_24 WHERE gold < 12 AND rank < 5 AND bronze = 5 | sql_create_context | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
When did Samsung Electronics Co LTD make the GT-i9100? | CREATE TABLE table_47482 (
"Company name" text,
"Hardware Model" text,
"Accreditation type" text,
"Accreditation level" text,
"Date" text
) | SELECT "Date" FROM table_47482 WHERE "Company name" = 'samsung electronics co ltd' AND "Hardware Model" = 'gt-i9100' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
what are the early morning flights from BOSTON to DENVER | CREATE TABLE time_interval (
period text,
begin_time int,
end_time int
)
CREATE TABLE flight_leg (
flight_id int,
leg_number int,
leg_flight int
)
CREATE TABLE airline (
airline_code varchar,
airline_name text,
note text
)
CREATE TABLE ground_service (
city_code text,
airport_code text,
transport_type text,
ground_fare int
)
CREATE TABLE class_of_service (
booking_class varchar,
rank int,
class_description text
)
CREATE TABLE restriction (
restriction_code text,
advance_purchase int,
stopovers text,
saturday_stay_required text,
minimum_stay int,
maximum_stay int,
application text,
no_discounts text
)
CREATE TABLE date_day (
month_number int,
day_number int,
year int,
day_name varchar
)
CREATE TABLE dual_carrier (
main_airline varchar,
low_flight_number int,
high_flight_number int,
dual_airline varchar,
service_name text
)
CREATE TABLE compartment_class (
compartment varchar,
class_type varchar
)
CREATE TABLE equipment_sequence (
aircraft_code_sequence varchar,
aircraft_code varchar
)
CREATE TABLE flight (
aircraft_code_sequence text,
airline_code varchar,
airline_flight text,
arrival_time int,
connections int,
departure_time int,
dual_carrier text,
flight_days text,
flight_id int,
flight_number int,
from_airport varchar,
meal_code text,
stops int,
time_elapsed int,
to_airport varchar
)
CREATE TABLE month (
month_number int,
month_name text
)
CREATE TABLE code_description (
code varchar,
description text
)
CREATE TABLE airport (
airport_code varchar,
airport_name text,
airport_location text,
state_code varchar,
country_name varchar,
time_zone_code varchar,
minimum_connect_time int
)
CREATE TABLE state (
state_code text,
state_name text,
country_name text
)
CREATE TABLE food_service (
meal_code text,
meal_number int,
compartment text,
meal_description varchar
)
CREATE TABLE city (
city_code varchar,
city_name varchar,
state_code varchar,
country_name varchar,
time_zone_code varchar
)
CREATE TABLE time_zone (
time_zone_code text,
time_zone_name text,
hours_from_gmt int
)
CREATE TABLE flight_stop (
flight_id int,
stop_number int,
stop_days text,
stop_airport text,
arrival_time int,
arrival_airline text,
arrival_flight_number int,
departure_time int,
departure_airline text,
departure_flight_number int,
stop_time int
)
CREATE TABLE flight_fare (
flight_id int,
fare_id int
)
CREATE TABLE days (
days_code varchar,
day_name varchar
)
CREATE TABLE fare_basis (
fare_basis_code text,
booking_class text,
class_type text,
premium text,
economy text,
discounted text,
night text,
season text,
basis_days text
)
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_required varchar
)
CREATE TABLE aircraft (
aircraft_code varchar,
aircraft_description varchar,
manufacturer varchar,
basic_type varchar,
engines int,
propulsion varchar,
wide_body varchar,
wing_span int,
length int,
weight int,
capacity int,
pay_load int,
cruising_speed int,
range_miles int,
pressurized varchar
)
CREATE TABLE airport_service (
city_code varchar,
airport_code varchar,
miles_distant int,
direction varchar,
minutes_distant int
) | SELECT DISTINCT flight.flight_id FROM airport_service AS AIRPORT_SERVICE_0, airport_service AS AIRPORT_SERVICE_1, city AS CITY_0, city AS CITY_1, flight WHERE (CITY_0.city_code = AIRPORT_SERVICE_0.city_code AND CITY_0.city_name = 'BOSTON' AND CITY_1.city_code = AIRPORT_SERVICE_1.city_code AND CITY_1.city_name = 'DENVER' AND flight.from_airport = AIRPORT_SERVICE_0.airport_code AND flight.to_airport = AIRPORT_SERVICE_1.airport_code) AND flight.departure_time BETWEEN 0 AND 800 | atis | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Name the most 3 credits | CREATE TABLE table_148535_2 (
Id VARCHAR
) | SELECT MIN(3 AS _credits) FROM table_148535_2 | sql_create_context | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is every yellow jersey entry for the distance 125? | CREATE TABLE table_3791 (
"Year" text,
"Stage" real,
"Start of stage" text,
"Distance (km)" text,
"Category of climb" text,
"Stage winner" text,
"Nationality" text,
"Yellow jersey" text,
"Bend" real
) | SELECT "Yellow jersey" FROM table_3791 WHERE "Distance (km)" = '125' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
In what years was there a rank lower than 9, under 84 goals, and more than 158 matches? | CREATE TABLE table_name_63 (
years VARCHAR,
goals VARCHAR,
matches VARCHAR,
rank VARCHAR
) | SELECT years FROM table_name_63 WHERE matches > 158 AND rank > 9 AND goals < 84 | sql_create_context | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What aired at 10:00 when Flashpoint aired at 9:30? | CREATE TABLE table_43208 (
"8:00" text,
"8:30" text,
"9:00" text,
"9:30" text,
"10:00" text
) | SELECT "10:00" FROM table_43208 WHERE "9:30" = 'flashpoint' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
count the number of patients whose insurance is government and procedure short title is rt/left heart card cath? | CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE demographic (
subject_id text,
hadm_id text,
name text,
marital_status text,
age text,
dob text,
gender text,
language text,
religion text,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location text,
discharge_location text,
diagnosis text,
dod text,
dob_year text,
dod_year text,
admittime text,
dischtime text,
admityear text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE prescriptions (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
)
CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
) | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN procedures ON demographic.hadm_id = procedures.hadm_id WHERE demographic.insurance = "Government" AND procedures.short_title = "Rt/left heart card cath" | mimicsql_data | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What was the record of the game in which Dydek (10) did the most high rebounds? | CREATE TABLE table_18904831_5 (
record VARCHAR,
high_rebounds VARCHAR
) | SELECT record FROM table_18904831_5 WHERE high_rebounds = "Dydek (10)" | sql_create_context | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
When was the game played at glenferrie oval? | CREATE TABLE table_10130 (
"Home team" text,
"Home team score" text,
"Away team" text,
"Away team score" text,
"Venue" text,
"Crowd" real,
"Date" text
) | SELECT "Date" FROM table_10130 WHERE "Venue" = 'glenferrie oval' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the highest K 2 O, when Na 2 O is greater than 1.87, when Fe 2 O 3 is greater than 0.07, when Objects is Ritual Disk, and when Al 2 O 3 is less than 0.62? | CREATE TABLE table_7207 (
"Objects" text,
"Date" text,
"SiO 2" real,
"Al 2 O 3" real,
"Fe 2 O 3" real,
"K 2 O" real,
"Na 2 O" real
) | SELECT MAX("K 2 O") FROM table_7207 WHERE "Na 2 O" > '1.87' AND "Fe 2 O 3" > '0.07' AND "Objects" = 'ritual disk' AND "Al 2 O 3" < '0.62' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
what is the total number of patients diagnosed with icd9 code 45620 who had a blood test. | CREATE TABLE prescriptions (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
)
CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE demographic (
subject_id text,
hadm_id text,
name text,
marital_status text,
age text,
dob text,
gender text,
language text,
religion text,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location text,
discharge_location text,
diagnosis text,
dod text,
dob_year text,
dod_year text,
admittime text,
dischtime text,
admityear text
) | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN diagnoses ON demographic.hadm_id = diagnoses.hadm_id INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE diagnoses.icd9_code = "45620" AND lab.fluid = "Blood" | mimicsql_data | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
count the number of patients whose primary disease is pneumonia;human immunodefiency virus;rule out tuberculosis and year of death is less than or equal to 2168? | CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE demographic (
subject_id text,
hadm_id text,
name text,
marital_status text,
age text,
dob text,
gender text,
language text,
religion text,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location text,
discharge_location text,
diagnosis text,
dod text,
dob_year text,
dod_year text,
admittime text,
dischtime text,
admityear text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE prescriptions (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
)
CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
) | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic WHERE demographic.diagnosis = "PNEUMONIA;HUMAN IMMUNODEFIENCY VIRUS;RULE OUT TUBERCULOSIS" AND demographic.dod_year <= "2168.0" | mimicsql_data | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Which section is in the 6th position? | CREATE TABLE table_72013 (
"Season" text,
"Level" text,
"Division" text,
"Section" text,
"Position" text
) | SELECT "Section" FROM table_72013 WHERE "Position" = '6th' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the area of the coed school with a state authority and a roll number of 122? | CREATE TABLE table_69300 (
"Name" text,
"Years" text,
"Gender" text,
"Area" text,
"Authority" text,
"Decile" real,
"Roll" real
) | SELECT "Area" FROM table_69300 WHERE "Authority" = 'state' AND "Gender" = 'coed' AND "Roll" = '122' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Which type of institution is in Amherst, MA? | CREATE TABLE table_name_1 (
type VARCHAR,
location VARCHAR
) | SELECT type FROM table_name_1 WHERE location = "amherst, ma" | sql_create_context | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What years did Birger Ruud win the FIS Nordic World Ski Championships? | CREATE TABLE table_21696 (
"Winner" text,
"Country" text,
"Winter Olympics" text,
"FIS Nordic World Ski Championships" text,
"Holmenkollen" text
) | SELECT "FIS Nordic World Ski Championships" FROM table_21696 WHERE "Winner" = 'Birger Ruud' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
how many members of estonia 's men 's national volleyball team were born in 1988 ? | CREATE TABLE table_203_116 (
id number,
"no." number,
"player" text,
"birth date" text,
"weight" number,
"height" number,
"position" text,
"current club" text
) | SELECT COUNT("player") FROM table_203_116 WHERE "birth date" = 1988 | squall | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What episoe number in the season originally aired on February 11, 1988? | CREATE TABLE table_2818164_5 (
no_in_season VARCHAR,
original_air_date VARCHAR
) | SELECT no_in_season FROM table_2818164_5 WHERE original_air_date = "February 11, 1988" | sql_create_context | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What date was the match against adri n men ndez-maceiras? | CREATE TABLE table_60686 (
"Date" text,
"Tournament" text,
"Surface" text,
"Opponent" text,
"Score" text
) | SELECT "Date" FROM table_60686 WHERE "Opponent" = 'adrián menéndez-maceiras' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
did shoko goto make more films in 2004 or 2005 ? | CREATE TABLE table_203_365 (
id number,
"released" text,
"video title" text,
"company" text,
"director" text,
"notes" text
) | SELECT "released" FROM table_203_365 WHERE "released" IN (2004, 2005) GROUP BY "released" ORDER BY COUNT("video title") DESC LIMIT 1 | squall | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What venue listed is dated February 22, 2003? | CREATE TABLE table_65116 (
"Date" text,
"Venue" text,
"Score" text,
"Result" text,
"Competition" text
) | SELECT "Venue" FROM table_65116 WHERE "Date" = 'february 22, 2003' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
provide the number of patients whose admission type is emergency and lab test name is rbc, csf? | CREATE TABLE prescriptions (
subject_id text,
hadm_id text,
icustay_id text,
drug_type text,
drug text,
formulary_drug_cd text,
route text,
drug_dose text
)
CREATE TABLE procedures (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
)
CREATE TABLE demographic (
subject_id text,
hadm_id text,
name text,
marital_status text,
age text,
dob text,
gender text,
language text,
religion text,
admission_type text,
days_stay text,
insurance text,
ethnicity text,
expire_flag text,
admission_location text,
discharge_location text,
diagnosis text,
dod text,
dob_year text,
dod_year text,
admittime text,
dischtime text,
admityear text
)
CREATE TABLE lab (
subject_id text,
hadm_id text,
itemid text,
charttime text,
flag text,
value_unit text,
label text,
fluid text
)
CREATE TABLE diagnoses (
subject_id text,
hadm_id text,
icd9_code text,
short_title text,
long_title text
) | SELECT COUNT(DISTINCT demographic.subject_id) FROM demographic INNER JOIN lab ON demographic.hadm_id = lab.hadm_id WHERE demographic.admission_type = "EMERGENCY" AND lab.label = "RBC, CSF" | mimicsql_data | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
How often does the course POLSCI 659 meet ? | CREATE TABLE course (
course_id int,
name varchar,
department varchar,
number varchar,
credits varchar,
advisory_requirement varchar,
enforced_requirement varchar,
description varchar,
num_semesters int,
num_enrolled int,
has_discussion varchar,
has_lab varchar,
has_projects varchar,
has_exams varchar,
num_reviews int,
clarity_score int,
easiness_score int,
helpfulness_score int
)
CREATE TABLE comment_instructor (
instructor_id int,
student_id int,
score int,
comment_text varchar
)
CREATE TABLE course_offering (
offering_id int,
course_id int,
semester int,
section_number int,
start_time time,
end_time time,
monday varchar,
tuesday varchar,
wednesday varchar,
thursday varchar,
friday varchar,
saturday varchar,
sunday varchar,
has_final_project varchar,
has_final_exam varchar,
textbook varchar,
class_address varchar,
allow_audit varchar
)
CREATE TABLE instructor (
instructor_id int,
name varchar,
uniqname varchar
)
CREATE TABLE gsi (
course_offering_id int,
student_id int
)
CREATE TABLE student_record (
student_id int,
course_id int,
semester int,
grade varchar,
how varchar,
transfer_source varchar,
earn_credit varchar,
repeat_term varchar,
test_id varchar
)
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 int,
respected int,
participation int,
heavy_reading int,
tough_grader int,
hilarious int,
would_take_again int,
good_lecture int,
no_skip int
)
CREATE TABLE requirement (
requirement_id int,
requirement varchar,
college varchar
)
CREATE TABLE program (
program_id int,
name varchar,
college varchar,
introduction varchar
)
CREATE TABLE program_requirement (
program_id int,
category varchar,
min_credit int,
additional_req varchar
)
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 varchar
)
CREATE TABLE area (
course_id int,
area varchar
)
CREATE TABLE jobs (
job_id int,
job_title varchar,
description varchar,
requirement varchar,
city varchar,
state varchar,
country varchar,
zip int
)
CREATE TABLE program_course (
program_id int,
course_id int,
workload int,
category varchar
)
CREATE TABLE course_prerequisite (
pre_course_id int,
course_id int
)
CREATE TABLE semester (
semester_id int,
semester varchar,
year int
)
CREATE TABLE ta (
campus_job_id int,
student_id int,
location varchar
)
CREATE TABLE offering_instructor (
offering_instructor_id int,
offering_id int,
instructor_id int
) | SELECT DISTINCT course_offering.friday, course_offering.monday, course_offering.saturday, course_offering.sunday, course_offering.thursday, course_offering.tuesday, course_offering.wednesday FROM course INNER JOIN course_offering ON course.course_id = course_offering.course_id INNER JOIN semester ON semester.semester_id = course_offering.semester WHERE course.department = 'POLSCI' AND course.number = 659 AND semester.semester = 'WN' AND semester.year = 2016 | advising | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Which couple participated in the Contemporary style of dance? | CREATE TABLE table_40395 (
"Couple" text,
"Style" text,
"Music" text,
"Choreographer(s)" text,
"Results" text
) | SELECT "Couple" FROM table_40395 WHERE "Style" = 'contemporary' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Name the metrical equivalence for linha | CREATE TABLE table_28772 (
"Portuguese name" text,
"English name" text,
"Subdivides in" text,
"Equivalence in Varas" text,
"Metrical equivalence" text
) | SELECT "Metrical equivalence" FROM table_28772 WHERE "Portuguese name" = 'Linha' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
If the college is SMU, what is the position? | CREATE TABLE table_27132791_3 (
position VARCHAR,
college VARCHAR
) | SELECT position FROM table_27132791_3 WHERE college = "SMU" | sql_create_context | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What was the represented team on June 27? | CREATE TABLE table_21876 (
"Season" real,
"Date" text,
"Winning Driver" text,
"Car #" real,
"Sponsor" text,
"Make" text,
"Team" text,
"Avg Speed" text,
"Margin of Victory" text
) | SELECT "Team" FROM table_21876 WHERE "Date" = 'June 27' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Please show the songs that have result 'nominated' at music festivals. | CREATE TABLE artist (
artist_id number,
artist text,
age number,
famous_title text,
famous_release_date text
)
CREATE TABLE music_festival (
id number,
music_festival text,
date_of_ceremony text,
category text,
volume number,
result text
)
CREATE TABLE volume (
volume_id number,
volume_issue text,
issue_date text,
weeks_on_top number,
song text,
artist_id number
) | SELECT T2.song FROM music_festival AS T1 JOIN volume AS T2 ON T1.volume = T2.volume_id WHERE T1.result = "Nominated" | spider | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Which teams had more than 3 eliminations? | CREATE TABLE elimination (
elimination_id text,
wrestler_id text,
team text,
eliminated_by text,
elimination_move text,
time text
)
CREATE TABLE wrestler (
wrestler_id number,
name text,
reign text,
days_held text,
location text,
event text
) | SELECT team FROM elimination GROUP BY team HAVING COUNT(*) > 3 | spider | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
how many athletes had a better result than tatyana bocharova ? | CREATE TABLE table_204_910 (
id number,
"rank" number,
"name" text,
"nationality" text,
"result" number,
"notes" text
) | SELECT COUNT("name") FROM table_204_910 WHERE "result" > (SELECT "result" FROM table_204_910 WHERE "name" = 'tatyana bocharova') | squall | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Which Type has a Capacity of 28 passengers, and a Number of 16? | CREATE TABLE table_8430 (
"Number" text,
"Builder" text,
"Type" text,
"Date" real,
"Length" text,
"Capacity" text
) | SELECT "Type" FROM table_8430 WHERE "Capacity" = '28 passengers' AND "Number" = '16' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Show the names of people, and dates and venues of debates they are on the negative side, ordered in ascending alphabetical order of name. | CREATE TABLE people (
people_id number,
district text,
name text,
party text,
age number
)
CREATE TABLE debate_people (
debate_id number,
affirmative number,
negative number,
if_affirmative_win others
)
CREATE TABLE debate (
debate_id number,
date text,
venue text,
num_of_audience number
) | SELECT T3.name, T2.date, T2.venue FROM debate_people AS T1 JOIN debate AS T2 ON T1.debate_id = T2.debate_id JOIN people AS T3 ON T1.negative = T3.people_id ORDER BY T3.name | spider | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
is a 2 credit full house the same as a 5 credit three of a kind ? | CREATE TABLE table_203_564 (
id number,
"hand" text,
"1 credit" number,
"2 credits" number,
"3 credits" number,
"4 credits" number,
"5 credits" number
) | SELECT (SELECT "2 credits" FROM table_203_564 WHERE "hand" = 'full house') = (SELECT "5 credits" FROM table_203_564 WHERE "hand" = 'three of a kind') | squall | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Next semester , what time does the EDUC 510 lecture begin ? | CREATE TABLE area (
course_id int,
area varchar
)
CREATE TABLE program (
program_id int,
name varchar,
college varchar,
introduction varchar
)
CREATE TABLE ta (
campus_job_id int,
student_id int,
location varchar
)
CREATE TABLE course (
course_id int,
name varchar,
department varchar,
number varchar,
credits varchar,
advisory_requirement varchar,
enforced_requirement varchar,
description varchar,
num_semesters int,
num_enrolled int,
has_discussion varchar,
has_lab varchar,
has_projects varchar,
has_exams varchar,
num_reviews int,
clarity_score int,
easiness_score int,
helpfulness_score int
)
CREATE TABLE offering_instructor (
offering_instructor_id int,
offering_id int,
instructor_id int
)
CREATE TABLE course_prerequisite (
pre_course_id int,
course_id int
)
CREATE TABLE requirement (
requirement_id int,
requirement varchar,
college varchar
)
CREATE TABLE jobs (
job_id int,
job_title varchar,
description varchar,
requirement varchar,
city varchar,
state varchar,
country varchar,
zip int
)
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 varchar
)
CREATE TABLE course_offering (
offering_id int,
course_id int,
semester int,
section_number int,
start_time time,
end_time time,
monday varchar,
tuesday varchar,
wednesday varchar,
thursday varchar,
friday varchar,
saturday varchar,
sunday varchar,
has_final_project varchar,
has_final_exam varchar,
textbook varchar,
class_address varchar,
allow_audit varchar
)
CREATE TABLE comment_instructor (
instructor_id int,
student_id int,
score int,
comment_text varchar
)
CREATE TABLE gsi (
course_offering_id int,
student_id int
)
CREATE TABLE program_course (
program_id int,
course_id int,
workload int,
category varchar
)
CREATE TABLE program_requirement (
program_id int,
category varchar,
min_credit int,
additional_req varchar
)
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 int,
respected int,
participation int,
heavy_reading int,
tough_grader int,
hilarious int,
would_take_again int,
good_lecture int,
no_skip int
)
CREATE TABLE student_record (
student_id int,
course_id int,
semester int,
grade varchar,
how varchar,
transfer_source varchar,
earn_credit varchar,
repeat_term varchar,
test_id varchar
)
CREATE TABLE semester (
semester_id int,
semester varchar,
year int
)
CREATE TABLE instructor (
instructor_id int,
name varchar,
uniqname varchar
) | SELECT DISTINCT course_offering.start_time FROM course INNER JOIN program_course ON program_course.course_id = course.course_id INNER JOIN course_offering ON course.course_id = course_offering.course_id INNER JOIN semester ON semester.semester_id = course_offering.semester WHERE course.department = 'EDUC' AND course.number = 510 AND semester.semester = 'FA' AND semester.year = 2016 | advising | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
For those records from the products and each product's manufacturer, a bar chart shows the distribution of name and the sum of code , and group by attribute name, sort total number of code in asc order. | CREATE TABLE Manufacturers (
Code INTEGER,
Name VARCHAR(255),
Headquarter VARCHAR(255),
Founder VARCHAR(255),
Revenue REAL
)
CREATE TABLE Products (
Code INTEGER,
Name VARCHAR(255),
Price DECIMAL,
Manufacturer INTEGER
) | SELECT T2.Name, T1.Code FROM Products AS T1 JOIN Manufacturers AS T2 ON T1.Manufacturer = T2.Code GROUP BY T2.Name ORDER BY T1.Code | nvbench | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What was the highest round that had northwestern? | CREATE TABLE table_name_18 (
round INTEGER,
school VARCHAR
) | SELECT MAX(round) FROM table_name_18 WHERE school = "northwestern" | sql_create_context | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What is the smallest Wins with a Position of 20th, and Poles smaller than 0? | CREATE TABLE table_name_19 (
wins INTEGER,
position VARCHAR,
poles VARCHAR
) | SELECT MIN(wins) FROM table_name_19 WHERE position = "20th" AND poles < 0 | sql_create_context | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
Who is listed under mens singles when womens has wang nan zhang yining? | CREATE TABLE table_30306 (
"Year Location" text,
"Mens Singles" text,
"Womens Singles" text,
"Mens Doubles" text,
"Womens Doubles" text
) | SELECT "Mens Singles" FROM table_30306 WHERE "Womens Doubles" = 'Wang Nan Zhang Yining' | wikisql | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
What are the start and end dates for incidents with incident type code 'NOISE'? | CREATE TABLE Behavior_Incident (
date_incident_start VARCHAR,
date_incident_end VARCHAR,
incident_type_code VARCHAR
) | SELECT date_incident_start, date_incident_end FROM Behavior_Incident WHERE incident_type_code = "NOISE" | sql_create_context | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
128000,
128006,
9125,
128007,
271,
38766,
1303,
33025,
2696,
25,
6790,
220,
2366,
18,
198,
15724,
2696,
25,
220,
1721,
4723,
220,
2366,
20,
271,
2675,
527,
264,
7941,
1887,
28175,
304,
... | [
[
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
End of preview. Expand
in Data Studio
README.md exists but content is empty.
- Downloads last month
- 23