output stringlengths 27 479 | instruction stringlengths 407 1.39k |
|---|---|
SELECT MAX("production_code") FROM "table1_23793770_1" WHERE "u_s_viewers_millions"='16.10'; |
## Task
Generate a SQL query to answer the following question:
`What the production code for the episode with 16.10 U.S. viewers?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23793770_1" (
"no_in_series" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text,
"production_code" real,
"u_s_viewers_millions" text
);
### SQL
Given the database schema, here is the SQL query that answers `What the production code for the episode with 16.10 U.S. viewers?`:
```sql
|
SELECT "title" FROM "ratings" WHERE "original_airing"='September 30, 2007'; |
## Task
Generate a SQL query to answer the following question:
`what is the episode title on original air date of September 30, 2007?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ratings" (
"episode_number_production_number" text,
"title" text,
"original_airing" text,
"rating" text,
"share" real,
"rating_share_18_49" text,
"total_viewers_in_millions" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the episode title on original air date of September 30, 2007?`:
```sql
|
SELECT "rating" FROM "ratings" WHERE "rating_share_18_49"='3.6'; |
## Task
Generate a SQL query to answer the following question:
`What is the rating if the rating/share (18-49) is 3.6?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ratings" (
"episode_number_production_number" text,
"title" text,
"original_airing" text,
"rating" text,
"share" real,
"rating_share_18_49" text,
"total_viewers_in_millions" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the rating if the rating/share (18-49) is 3.6?`:
```sql
|
SELECT COUNT("rating_share_18_49") FROM "ratings" WHERE "total_viewers_in_millions"='12.75'; |
## Task
Generate a SQL query to answer the following question:
`What is the rating/share total number if the total viewers is 12.75 million?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ratings" (
"episode_number_production_number" text,
"title" text,
"original_airing" text,
"rating" text,
"share" real,
"rating_share_18_49" text,
"total_viewers_in_millions" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the rating/share total number if the total viewers is 12.75 million?`:
```sql
|
SELECT "total_viewers_in_millions" FROM "ratings" WHERE "rating"='9.1'; |
## Task
Generate a SQL query to answer the following question:
`If the rating is 9.1, what was the total viewers?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ratings" (
"episode_number_production_number" text,
"title" text,
"original_airing" text,
"rating" text,
"share" real,
"rating_share_18_49" text,
"total_viewers_in_millions" text
);
### SQL
Given the database schema, here is the SQL query that answers `If the rating is 9.1, what was the total viewers?`:
```sql
|
SELECT "rating_share_18_49" FROM "ratings" WHERE "total_viewers_in_millions"='11.49'; |
## Task
Generate a SQL query to answer the following question:
`What was the reating share when the total viewers was 11.49 million?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ratings" (
"episode_number_production_number" text,
"title" text,
"original_airing" text,
"rating" text,
"share" real,
"rating_share_18_49" text,
"total_viewers_in_millions" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the reating share when the total viewers was 11.49 million?`:
```sql
|
SELECT "title" FROM "ratings" WHERE "total_viewers_in_millions"='10.47'; |
## Task
Generate a SQL query to answer the following question:
`What was the name of the show that had 10.47 million total viewers?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ratings" (
"episode_number_production_number" text,
"title" text,
"original_airing" text,
"rating" text,
"share" real,
"rating_share_18_49" text,
"total_viewers_in_millions" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the name of the show that had 10.47 million total viewers?`:
```sql
|
SELECT COUNT("title") FROM "ratings" WHERE "total_viewers_in_millions"='12.46'; |
## Task
Generate a SQL query to answer the following question:
`How many shows had 12.46 total viewers?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ratings" (
"episode_number_production_number" text,
"title" text,
"original_airing" text,
"rating" text,
"share" real,
"rating_share_18_49" text,
"total_viewers_in_millions" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many shows had 12.46 total viewers?`:
```sql
|
SELECT "title" FROM "ratings" WHERE "total_viewers_in_millions"='10.47'; |
## Task
Generate a SQL query to answer the following question:
`What episode had 10.47 total viewers? `
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ratings" (
"episode_number_production_number" text,
"title" text,
"original_airing" text,
"rating" text,
"share" real,
"rating_share_18_49" text,
"total_viewers_in_millions" text
);
### SQL
Given the database schema, here is the SQL query that answers `What episode had 10.47 total viewers? `:
```sql
|
SELECT MAX("sales_receipts_or_shipments_1_000") FROM "table1_23802822_1" WHERE "establishments"=49319; |
## Task
Generate a SQL query to answer the following question:
`If the establishment is 49319, what is the sales, receipts or shipments maximum amount?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23802822_1" (
"sector" text,
"establishments" real,
"sales_receipts_or_shipments_1_000" real,
"annual_payroll_1_000" real,
"paid_employees" real
);
### SQL
Given the database schema, here is the SQL query that answers `If the establishment is 49319, what is the sales, receipts or shipments maximum amount?`:
```sql
|
SELECT "establishments" FROM "table1_23802822_1" WHERE "annual_payroll_1_000"=21173895; |
## Task
Generate a SQL query to answer the following question:
`If the annual payroll is 21173895, what is the establishments?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23802822_1" (
"sector" text,
"establishments" real,
"sales_receipts_or_shipments_1_000" real,
"annual_payroll_1_000" real,
"paid_employees" real
);
### SQL
Given the database schema, here is the SQL query that answers `If the annual payroll is 21173895, what is the establishments?`:
```sql
|
SELECT "sector" FROM "table1_23802822_1" WHERE "establishments"=110313; |
## Task
Generate a SQL query to answer the following question:
`What is the sector is the establishment is 110313?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23802822_1" (
"sector" text,
"establishments" real,
"sales_receipts_or_shipments_1_000" real,
"annual_payroll_1_000" real,
"paid_employees" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the sector is the establishment is 110313?`:
```sql
|
SELECT COUNT("league") FROM "year_by_year" WHERE "avg_attendance"=3589; |
## Task
Generate a SQL query to answer the following question:
`How many different Leagues had average attendance of 3589?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "year_by_year" (
"year" real,
"division" real,
"league" text,
"regular_season" text,
"playoffs" text,
"open_cup" text,
"avg_attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many different Leagues had average attendance of 3589?`:
```sql
|
SELECT MIN("avg_attendance") FROM "year_by_year" WHERE "regular_season"='3rd, Central'; |
## Task
Generate a SQL query to answer the following question:
`How many people saw the 3rd, Central regular season on average?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "year_by_year" (
"year" real,
"division" real,
"league" text,
"regular_season" text,
"playoffs" text,
"open_cup" text,
"avg_attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many people saw the 3rd, Central regular season on average?`:
```sql
|
SELECT "league" FROM "year_by_year" WHERE "year"=2007; |
## Task
Generate a SQL query to answer the following question:
`What League was played in 2007?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "year_by_year" (
"year" real,
"division" real,
"league" text,
"regular_season" text,
"playoffs" text,
"open_cup" text,
"avg_attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `What League was played in 2007?`:
```sql
|
SELECT MIN("year") FROM "year_by_year" WHERE "avg_attendance"=789; |
## Task
Generate a SQL query to answer the following question:
`When was the average attendance 789?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "year_by_year" (
"year" real,
"division" real,
"league" text,
"regular_season" text,
"playoffs" text,
"open_cup" text,
"avg_attendance" real
);
### SQL
Given the database schema, here is the SQL query that answers `When was the average attendance 789?`:
```sql
|
SELECT "fg_fga" FROM "player_stats" WHERE "ft_fta"='16-21'; |
## Task
Generate a SQL query to answer the following question:
`what is the score in fg-fga if in ft-fta is 16-21`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "player_stats" (
"player" text,
"gp_gs" text,
"min_avg" text,
"fg_fga" text,
"fg_pct" text,
"3_fg_fga" text,
"3_fg_pct" text,
"ft_fta" text,
"ft_pct" text,
"reb" real,
"ast" real,
"blk" real,
"stl" real,
"pts" real,
"avg_pts" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the score in fg-fga if in ft-fta is 16-21`:
```sql
|
SELECT COUNT("ft_pct") FROM "player_stats" WHERE "3_fg_fga"='1-20'; |
## Task
Generate a SQL query to answer the following question:
`if the 3fg-fga is 1-20 what is the number in ft pct`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "player_stats" (
"player" text,
"gp_gs" text,
"min_avg" text,
"fg_fga" text,
"fg_pct" text,
"3_fg_fga" text,
"3_fg_pct" text,
"ft_fta" text,
"ft_pct" text,
"reb" real,
"ast" real,
"blk" real,
"stl" real,
"pts" real,
"avg_pts" text
);
### SQL
Given the database schema, here is the SQL query that answers `if the 3fg-fga is 1-20 what is the number in ft pct`:
```sql
|
SELECT COUNT("gp_gs") FROM "player_stats" WHERE "ft_pct"='.667'; |
## Task
Generate a SQL query to answer the following question:
`in the ft pct .667 what is the number of gp-gs`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "player_stats" (
"player" text,
"gp_gs" text,
"min_avg" text,
"fg_fga" text,
"fg_pct" text,
"3_fg_fga" text,
"3_fg_pct" text,
"ft_fta" text,
"ft_pct" text,
"reb" real,
"ast" real,
"blk" real,
"stl" real,
"pts" real,
"avg_pts" text
);
### SQL
Given the database schema, here is the SQL query that answers `in the ft pct .667 what is the number of gp-gs`:
```sql
|
SELECT "team_num1" FROM "matches" WHERE "team_num2"='San Lorenzo'; |
## Task
Generate a SQL query to answer the following question:
`Name the team number 1 for san lorenzo`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "matches" (
"team_num1" text,
"points" text,
"team_num2" text,
"1st_leg" text,
"2nd_leg" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the team number 1 for san lorenzo`:
```sql
|
SELECT "team_num2" FROM "matches" WHERE "team_num1"='River Plate'; |
## Task
Generate a SQL query to answer the following question:
`Name the team #2 for river plate`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "matches" (
"team_num1" text,
"points" text,
"team_num2" text,
"1st_leg" text,
"2nd_leg" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the team #2 for river plate`:
```sql
|
SELECT "points" FROM "matches" WHERE "team_num1"='Zamora'; |
## Task
Generate a SQL query to answer the following question:
`Name the points for zamora`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "matches" (
"team_num1" text,
"points" text,
"team_num2" text,
"1st_leg" text,
"2nd_leg" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the points for zamora`:
```sql
|
SELECT "2nd_leg" FROM "matches" WHERE "team_num1"='Boca Juniors'; |
## Task
Generate a SQL query to answer the following question:
`Name the 2nd leg for boca juniors`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "matches" (
"team_num1" text,
"points" text,
"team_num2" text,
"1st_leg" text,
"2nd_leg" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the 2nd leg for boca juniors`:
```sql
|
SELECT "media_type" FROM "list_of_works_sampling_spectrasonics" WHERE "genre"='Psychedelic Trance'; |
## Task
Generate a SQL query to answer the following question:
`What is every media type for the Psychedelic Trance genre?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_works_sampling_spectrasonics" (
"music_library" text,
"year" real,
"media_type" text,
"name_of_the_media" text,
"composition_name" text,
"composer" text,
"genre" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is every media type for the Psychedelic Trance genre?`:
```sql
|
SELECT "composer" FROM "list_of_works_sampling_spectrasonics" WHERE "name_of_the_media"='Hall Of Dreams'; |
## Task
Generate a SQL query to answer the following question:
`Who is every composer for the media named Hall of Dreams?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_works_sampling_spectrasonics" (
"music_library" text,
"year" real,
"media_type" text,
"name_of_the_media" text,
"composition_name" text,
"composer" text,
"genre" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is every composer for the media named Hall of Dreams?`:
```sql
|
SELECT "media_type" FROM "list_of_works_sampling_spectrasonics" WHERE "genre"='Dub'; |
## Task
Generate a SQL query to answer the following question:
`What is every media type for the Dub genre?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_works_sampling_spectrasonics" (
"music_library" text,
"year" real,
"media_type" text,
"name_of_the_media" text,
"composition_name" text,
"composer" text,
"genre" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is every media type for the Dub genre?`:
```sql
|
SELECT "media_type" FROM "list_of_works_sampling_spectrasonics" WHERE "genre"='World'; |
## Task
Generate a SQL query to answer the following question:
`What is every media type for the World genre?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_works_sampling_spectrasonics" (
"music_library" text,
"year" real,
"media_type" text,
"name_of_the_media" text,
"composition_name" text,
"composer" text,
"genre" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is every media type for the World genre?`:
```sql
|
SELECT "composition_name" FROM "list_of_works_sampling_spectrasonics" WHERE "music_library"='Heart of Asia' AND "media_type"='Album' AND "genre"='Trance'; |
## Task
Generate a SQL query to answer the following question:
`What is every composition name when the music library is Heart of Asia and media type is album with the Trance genre?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "list_of_works_sampling_spectrasonics" (
"music_library" text,
"year" real,
"media_type" text,
"name_of_the_media" text,
"composition_name" text,
"composer" text,
"genre" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is every composition name when the music library is Heart of Asia and media type is album with the Trance genre?`:
```sql
|
SELECT "k_mathrm_h_cc_frac_c_mathrm_aq_c_mathrm_gas" FROM "table1_238199_1" WHERE "k_mathrm_h_cp_frac_c_mathrm_aq_p"='7.8 × 10−4'; |
## Task
Generate a SQL query to answer the following question:
`What was the '{\mathrm{h,cc}} = \frac{c_{\mathrm{aq}}}{c_{\mathrm{gas}}}' if '_{\mathrm{h,cp}} = \frac{c_\mathrm{aq}}{p}' is 7.8 × 10−4?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_238199_1" (
"equation" text,
"k_mathrm_h_pc_frac_p_c_mathrm_aq" text,
"k_mathrm_h_cp_frac_c_mathrm_aq_p" text,
"k_mathrm_h_px_frac_p_x" text,
"k_mathrm_h_cc_frac_c_mathrm_aq_c_mathrm_gas" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the '{\mathrm{h,cc}} = \frac{c_{\mathrm{aq}}}{c_{\mathrm{gas}}}' if '_{\mathrm{h,cp}} = \frac{c_\mathrm{aq}}{p}' is 7.8 × 10−4?`:
```sql
|
SELECT "equation" FROM "table1_238199_1" WHERE "k_mathrm_h_px_frac_p_x"='12.30 × 10'; |
## Task
Generate a SQL query to answer the following question:
`What was the equation if k_{\mathrm{h,px}} = \frac{p}{x} is 12.30 × 10?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_238199_1" (
"equation" text,
"k_mathrm_h_pc_frac_p_c_mathrm_aq" text,
"k_mathrm_h_cp_frac_c_mathrm_aq_p" text,
"k_mathrm_h_px_frac_p_x" text,
"k_mathrm_h_cc_frac_c_mathrm_aq_c_mathrm_gas" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the equation if k_{\mathrm{h,px}} = \frac{p}{x} is 12.30 × 10?`:
```sql
|
SELECT "k_mathrm_h_cc_frac_c_mathrm_aq_c_mathrm_gas" FROM "table1_238199_1" WHERE "equation"='CO 2'; |
## Task
Generate a SQL query to answer the following question:
`What wast the 'k_{\mathrm{h,cc}} = \frac{c_{\mathrm{aq}}}{c_{\mathrm{gas}}}' of CO 2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_238199_1" (
"equation" text,
"k_mathrm_h_pc_frac_p_c_mathrm_aq" text,
"k_mathrm_h_cp_frac_c_mathrm_aq_p" text,
"k_mathrm_h_px_frac_p_x" text,
"k_mathrm_h_cc_frac_c_mathrm_aq_c_mathrm_gas" text
);
### SQL
Given the database schema, here is the SQL query that answers `What wast the 'k_{\mathrm{h,cc}} = \frac{c_{\mathrm{aq}}}{c_{\mathrm{gas}}}' of CO 2?`:
```sql
|
SELECT COUNT("k_mathrm_h_cc_frac_c_mathrm_aq_c_mathrm_gas") FROM "table1_238199_1" WHERE "k_mathrm_h_px_frac_p_x"='14.97 × 10'; |
## Task
Generate a SQL query to answer the following question:
`How many "k_{\mathrm{h,cc}} = \frac{c_{\mathrm{aq}}}{c_{\mathrm{gas}}}i if its 'k_{\mathrm{h,px}} = \frac{p}{x}' is 14.97 × 10?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_238199_1" (
"equation" text,
"k_mathrm_h_pc_frac_p_c_mathrm_aq" text,
"k_mathrm_h_cp_frac_c_mathrm_aq_p" text,
"k_mathrm_h_px_frac_p_x" text,
"k_mathrm_h_cc_frac_c_mathrm_aq_c_mathrm_gas" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many "k_{\mathrm{h,cc}} = \frac{c_{\mathrm{aq}}}{c_{\mathrm{gas}}}i if its 'k_{\mathrm{h,px}} = \frac{p}{x}' is 14.97 × 10?`:
```sql
|
SELECT "equation" FROM "table1_238199_1" WHERE "k_mathrm_h_pc_frac_p_c_mathrm_aq"='2222.22'; |
## Task
Generate a SQL query to answer the following question:
`What was the equation if k_{\mathrm{h,pc}} = \frac{p}{c_\mathrm{aq}} is 2222.22?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_238199_1" (
"equation" text,
"k_mathrm_h_pc_frac_p_c_mathrm_aq" text,
"k_mathrm_h_cp_frac_c_mathrm_aq_p" text,
"k_mathrm_h_px_frac_p_x" text,
"k_mathrm_h_cc_frac_c_mathrm_aq_c_mathrm_gas" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the equation if k_{\mathrm{h,pc}} = \frac{p}{c_\mathrm{aq}} is 2222.22?`:
```sql
|
SELECT "k_mathrm_h_cc_frac_c_mathrm_aq_c_mathrm_gas" FROM "table1_238199_1" WHERE "equation"='O 2'; |
## Task
Generate a SQL query to answer the following question:
`What is the 'k_{\mathrm{h,cc}} = \frac{c_{\mathrm{aq}}}{c_{\mathrm{gas}}}' of O 2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_238199_1" (
"equation" text,
"k_mathrm_h_pc_frac_p_c_mathrm_aq" text,
"k_mathrm_h_cp_frac_c_mathrm_aq_p" text,
"k_mathrm_h_px_frac_p_x" text,
"k_mathrm_h_cc_frac_c_mathrm_aq_c_mathrm_gas" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 'k_{\mathrm{h,cc}} = \frac{c_{\mathrm{aq}}}{c_{\mathrm{gas}}}' of O 2?`:
```sql
|
SELECT "brooklyn" FROM "general_election" WHERE "manhattan"='15.5%'; |
## Task
Generate a SQL query to answer the following question:
`what percentage is brooklyn when manhattan is 15.5%?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "general_election" (
"2009_general_election" text,
"party" text,
"manhattan" text,
"the_bronx" text,
"brooklyn" text,
"queens" text,
"staten_island" text,
"total" real,
"pct" text
);
### SQL
Given the database schema, here is the SQL query that answers `what percentage is brooklyn when manhattan is 15.5%?`:
```sql
|
SELECT "qld_cup_premierships" FROM "previous_teams" WHERE "home_ground"='Dairy Farmers Stadium'; |
## Task
Generate a SQL query to answer the following question:
`What is every entry in the QLD Cup Premierships when home ground is Dairy Farmers Stadium?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "previous_teams" (
"team" text,
"location" text,
"home_ground" text,
"first_year_in_qld_cup" real,
"last_year_in_qld_cup" real,
"qld_cup_premierships" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is every entry in the QLD Cup Premierships when home ground is Dairy Farmers Stadium?`:
```sql
|
SELECT "first_year_in_qld_cup" FROM "previous_teams" WHERE "home_ground"='Corbett Park, Crosby Park, Lang Park, ANZ Stadium'; |
## Task
Generate a SQL query to answer the following question:
`What is every value for first year in QLD Cup if home ground is Corbett Park, Crosby Park, Lang Park, ANZ Stadium?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "previous_teams" (
"team" text,
"location" text,
"home_ground" text,
"first_year_in_qld_cup" real,
"last_year_in_qld_cup" real,
"qld_cup_premierships" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is every value for first year in QLD Cup if home ground is Corbett Park, Crosby Park, Lang Park, ANZ Stadium?`:
```sql
|
SELECT "home_ground" FROM "previous_teams" WHERE "team"='Sunshine Coast Falcons'; |
## Task
Generate a SQL query to answer the following question:
`What is the home ground if team is Sunshine Coast Falcons?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "previous_teams" (
"team" text,
"location" text,
"home_ground" text,
"first_year_in_qld_cup" real,
"last_year_in_qld_cup" real,
"qld_cup_premierships" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the home ground if team is Sunshine Coast Falcons?`:
```sql
|
SELECT "qld_cup_premierships" FROM "previous_teams" WHERE "team"='Gold Coast Vikings'; |
## Task
Generate a SQL query to answer the following question:
`What is the QLD Cup Premierships if team is Gold Coast Vikings?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "previous_teams" (
"team" text,
"location" text,
"home_ground" text,
"first_year_in_qld_cup" real,
"last_year_in_qld_cup" real,
"qld_cup_premierships" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the QLD Cup Premierships if team is Gold Coast Vikings?`:
```sql
|
SELECT "team" FROM "previous_teams" WHERE "location"='Port Moresby'; |
## Task
Generate a SQL query to answer the following question:
`What is every team in the location of Port Moresby?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "previous_teams" (
"team" text,
"location" text,
"home_ground" text,
"first_year_in_qld_cup" real,
"last_year_in_qld_cup" real,
"qld_cup_premierships" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is every team in the location of Port Moresby?`:
```sql
|
SELECT COUNT("last_year_in_qld_cup") FROM "previous_teams" WHERE "qld_cup_premierships"='1996, 2001'; |
## Task
Generate a SQL query to answer the following question:
`How many values of last year in QLD Cup if QLD Cup Premierships is 1996, 2001?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "previous_teams" (
"team" text,
"location" text,
"home_ground" text,
"first_year_in_qld_cup" real,
"last_year_in_qld_cup" real,
"qld_cup_premierships" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many values of last year in QLD Cup if QLD Cup Premierships is 1996, 2001?`:
```sql
|
SELECT "wycombe_wanderers" FROM "transfers" WHERE "1_january_2010"='23 July 2009' AND "df"='GK'; |
## Task
Generate a SQL query to answer the following question:
`What are the Wycombe Wanderers when 1 January 2010 is 23 July 2009 and df is gk?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "transfers" (
"1_january_2010" text,
"df" text,
"adam_hinshelwood" text,
"aldershot_town" text,
"wycombe_wanderers" text,
"undisclosed" text
);
### SQL
Given the database schema, here is the SQL query that answers `What are the Wycombe Wanderers when 1 January 2010 is 23 July 2009 and df is gk?`:
```sql
|
SELECT "undisclosed" FROM "transfers" WHERE "adam_hinshelwood"='Ricky Newman'; |
## Task
Generate a SQL query to answer the following question:
`What are the undisclosed when Adam Hinshelwood is Ricky Newman?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "transfers" (
"1_january_2010" text,
"df" text,
"adam_hinshelwood" text,
"aldershot_town" text,
"wycombe_wanderers" text,
"undisclosed" text
);
### SQL
Given the database schema, here is the SQL query that answers `What are the undisclosed when Adam Hinshelwood is Ricky Newman?`:
```sql
|
SELECT "df" FROM "transfers" WHERE "adam_hinshelwood"='Junior Mendes'; |
## Task
Generate a SQL query to answer the following question:
`What is the df when Adam Hinshelwood is Junior Mendes?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "transfers" (
"1_january_2010" text,
"df" text,
"adam_hinshelwood" text,
"aldershot_town" text,
"wycombe_wanderers" text,
"undisclosed" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the df when Adam Hinshelwood is Junior Mendes?`:
```sql
|
SELECT "undisclosed" FROM "transfers" WHERE "aldershot_town"='Aldershot Town' AND "wycombe_wanderers"='Oxford United'; |
## Task
Generate a SQL query to answer the following question:
`What is the undisclosed when Aldertown is Aldershot Town and Wycombe Wanderers is Oxford United?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "transfers" (
"1_january_2010" text,
"df" text,
"adam_hinshelwood" text,
"aldershot_town" text,
"wycombe_wanderers" text,
"undisclosed" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the undisclosed when Aldertown is Aldershot Town and Wycombe Wanderers is Oxford United?`:
```sql
|
SELECT "undisclosed" FROM "transfers" WHERE "wycombe_wanderers"='Unattached'; |
## Task
Generate a SQL query to answer the following question:
`What is the undisclosed when Wycombe Wanderers is unattached?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "transfers" (
"1_january_2010" text,
"df" text,
"adam_hinshelwood" text,
"aldershot_town" text,
"wycombe_wanderers" text,
"undisclosed" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the undisclosed when Wycombe Wanderers is unattached?`:
```sql
|
SELECT "head_coach" FROM "current_teams" WHERE "arena"='Altrincham Ice Dome'; |
## Task
Generate a SQL query to answer the following question:
`Who is the head coach for the team that plays at Altrincham Ice Dome?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "current_teams" (
"team" text,
"city_area" text,
"arena" text,
"founded" real,
"joined" real,
"head_coach" text,
"captain" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who is the head coach for the team that plays at Altrincham Ice Dome?`:
```sql
|
SELECT "arena" FROM "current_teams" WHERE "captain"='Michael Wales'; |
## Task
Generate a SQL query to answer the following question:
`What arena does the team play at that has Michael Wales as the captain?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "current_teams" (
"team" text,
"city_area" text,
"arena" text,
"founded" real,
"joined" real,
"head_coach" text,
"captain" text
);
### SQL
Given the database schema, here is the SQL query that answers `What arena does the team play at that has Michael Wales as the captain?`:
```sql
|
SELECT "theme" FROM "american_idol_performances" WHERE "week_num"='Top 9'; |
## Task
Generate a SQL query to answer the following question:
`List all themes from the top 9.`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "american_idol_performances" (
"week_num" text,
"theme" text,
"song_choice" text,
"original_artist" text,
"order_num" real,
"result" text
);
### SQL
Given the database schema, here is the SQL query that answers `List all themes from the top 9.`:
```sql
|
SELECT "week_num" FROM "american_idol_performances" WHERE "original_artist"='Whitney Houston'; |
## Task
Generate a SQL query to answer the following question:
`In what week was the original singer Whitney Houston.`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "american_idol_performances" (
"week_num" text,
"theme" text,
"song_choice" text,
"original_artist" text,
"order_num" real,
"result" text
);
### SQL
Given the database schema, here is the SQL query that answers `In what week was the original singer Whitney Houston.`:
```sql
|
SELECT "song_choice" FROM "american_idol_performances" WHERE "result"='Safe' AND "order_num"=8; |
## Task
Generate a SQL query to answer the following question:
`Name the song for safe result #8.`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "american_idol_performances" (
"week_num" text,
"theme" text,
"song_choice" text,
"original_artist" text,
"order_num" real,
"result" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the song for safe result #8.`:
```sql
|
SELECT "song_choice" FROM "american_idol_performances" WHERE "theme"='British Invasion'; |
## Task
Generate a SQL query to answer the following question:
`List the song chose for the British Invasion.`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "american_idol_performances" (
"week_num" text,
"theme" text,
"song_choice" text,
"original_artist" text,
"order_num" real,
"result" text
);
### SQL
Given the database schema, here is the SQL query that answers `List the song chose for the British Invasion.`:
```sql
|
SELECT "stops" FROM "circumvesuviana" WHERE "stations"=36; |
## Task
Generate a SQL query to answer the following question:
`Name the stops for stations 36`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "circumvesuviana" (
"lines" text,
"opening" real,
"traction" text,
"length" text,
"stations" real,
"route" text,
"stops" real,
"travel_time" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the stops for stations 36`:
```sql
|
SELECT COUNT("lines") FROM "circumvesuviana" WHERE "route"='Porta Nolana - Ottaviano- Sarno'; |
## Task
Generate a SQL query to answer the following question:
`Name the number of lines for porta nolana - ottaviano- sarno`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "circumvesuviana" (
"lines" text,
"opening" real,
"traction" text,
"length" text,
"stations" real,
"route" text,
"stops" real,
"travel_time" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the number of lines for porta nolana - ottaviano- sarno`:
```sql
|
SELECT "travel_time" FROM "circumvesuviana" WHERE "route"='Porta Nolana - Nola - Baiano'; |
## Task
Generate a SQL query to answer the following question:
`Name the travel time for porta nolana - nola - baiano`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "circumvesuviana" (
"lines" text,
"opening" real,
"traction" text,
"length" text,
"stations" real,
"route" text,
"stops" real,
"travel_time" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the travel time for porta nolana - nola - baiano`:
```sql
|
SELECT COUNT("stations") FROM "circumvesuviana" WHERE "travel_time"='15 minutes'; |
## Task
Generate a SQL query to answer the following question:
`Name the number of stations for 15 minutes travel time`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "circumvesuviana" (
"lines" text,
"opening" real,
"traction" text,
"length" text,
"stations" real,
"route" text,
"stops" real,
"travel_time" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the number of stations for 15 minutes travel time`:
```sql
|
SELECT "area_km" FROM "see_also" WHERE "province_ashkharh"='Persarmenia'; |
## Task
Generate a SQL query to answer the following question:
`How big (in km2) is Persarmenia?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "see_also" (
"province_ashkharh" text,
"armenian_name" text,
"area_km" real,
"number_of_cantons_gavars" real,
"center" text
);
### SQL
Given the database schema, here is the SQL query that answers `How big (in km2) is Persarmenia?`:
```sql
|
SELECT "center" FROM "see_also" WHERE "province_ashkharh"='Artsakh'; |
## Task
Generate a SQL query to answer the following question:
`What's the center of the Artsakh province?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "see_also" (
"province_ashkharh" text,
"armenian_name" text,
"area_km" real,
"number_of_cantons_gavars" real,
"center" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the center of the Artsakh province?`:
```sql
|
SELECT COUNT("province_ashkharh") FROM "see_also" WHERE "center"='Baghaberd'; |
## Task
Generate a SQL query to answer the following question:
`How many different provinces is Baghaberd the center of?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "see_also" (
"province_ashkharh" text,
"armenian_name" text,
"area_km" real,
"number_of_cantons_gavars" real,
"center" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many different provinces is Baghaberd the center of?`:
```sql
|
SELECT MIN("area_km") FROM "see_also" WHERE "armenian_name"='Փայտակարան'; |
## Task
Generate a SQL query to answer the following question:
`How big is the province with the Armenian name of փայտակարան?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "see_also" (
"province_ashkharh" text,
"armenian_name" text,
"area_km" real,
"number_of_cantons_gavars" real,
"center" text
);
### SQL
Given the database schema, here is the SQL query that answers `How big is the province with the Armenian name of փայտակարան?`:
```sql
|
SELECT "center" FROM "see_also" WHERE "area_km"=23860; |
## Task
Generate a SQL query to answer the following question:
`What's the center of the province that spreads out on 23860 km2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "see_also" (
"province_ashkharh" text,
"armenian_name" text,
"area_km" real,
"number_of_cantons_gavars" real,
"center" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the center of the province that spreads out on 23860 km2?`:
```sql
|
SELECT COUNT("number_of_cantons_gavars") FROM "see_also" WHERE "armenian_name"='Վասպուրական'; |
## Task
Generate a SQL query to answer the following question:
`How many different numbers of cantons does the province with the Armenian name վասպուրական have?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "see_also" (
"province_ashkharh" text,
"armenian_name" text,
"area_km" real,
"number_of_cantons_gavars" real,
"center" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many different numbers of cantons does the province with the Armenian name վասպուրական have?`:
```sql
|
SELECT "seasons" FROM "table1_23886181_1" WHERE "no"='3'; |
## Task
Generate a SQL query to answer the following question:
`what are the seasons for no 3?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23886181_1" (
"no" text,
"football_club" text,
"continent" text,
"associated_football_club" text,
"seasons" text,
"racing_drivers" text
);
### SQL
Given the database schema, here is the SQL query that answers `what are the seasons for no 3?`:
```sql
|
SELECT MAX("wins") FROM "nascar_sprint_cup_series" WHERE "poles"=2; |
## Task
Generate a SQL query to answer the following question:
`what are the maximum wins where the poles are 2?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "nascar_sprint_cup_series" (
"year" real,
"starts" real,
"wins" real,
"top_5" real,
"top_10" real,
"poles" real,
"avg_start" text,
"avg_finish" text,
"winnings" text,
"position" text,
"team_s" text
);
### SQL
Given the database schema, here is the SQL query that answers `what are the maximum wins where the poles are 2?`:
```sql
|
SELECT "translation" FROM "examples_of_different_pronunciation" WHERE "ipa_rio_de_janeiro"='ki̥ mo̞ɕˈtɾaɾɜ̃w̃ nɐ ˈtɛʁə tɕĩʑiˈtɜ̃nə'; |
## Task
Generate a SQL query to answer the following question:
`What is the original of the ipa ( rio de janeiro )translation ki̥ mo̞ɕˈtɾaɾɜ̃w̃ nɐ ˈtɛʁə tɕĩʑiˈtɜ̃nə?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "examples_of_different_pronunciation" (
"original" text,
"ipa_lisbon" text,
"ipa_rio_de_janeiro" text,
"ipa_s_o_paulo" text,
"ipa_santiago_de_compostela" text,
"translation" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the original of the ipa ( rio de janeiro )translation ki̥ mo̞ɕˈtɾaɾɜ̃w̃ nɐ ˈtɛʁə tɕĩʑiˈtɜ̃nə?`:
```sql
|
SELECT "translation" FROM "examples_of_different_pronunciation" WHERE "ipa_s_o_paulo"='dɐ̃ːˈtɕiɣɐ ˈtɐ̃ʊ̯̃ ɐ̃ˈmadɐ ˈsuɐ ɦõ̞ˈmənə'; |
## Task
Generate a SQL query to answer the following question:
`What is the original of the ipa ( são paulo ) translation dɐ̃ːˈtɕiɣɐ ˈtɐ̃ʊ̯̃ ɐ̃ˈmadɐ ˈsuɐ ɦõ̞ˈmənə?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "examples_of_different_pronunciation" (
"original" text,
"ipa_lisbon" text,
"ipa_rio_de_janeiro" text,
"ipa_s_o_paulo" text,
"ipa_santiago_de_compostela" text,
"translation" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the original of the ipa ( são paulo ) translation dɐ̃ːˈtɕiɣɐ ˈtɐ̃ʊ̯̃ ɐ̃ˈmadɐ ˈsuɐ ɦõ̞ˈmənə?`:
```sql
|
SELECT "frequency" FROM "easy_rock_stations" WHERE "callsign"='DYMY'; |
## Task
Generate a SQL query to answer the following question:
`Which frequency is DYMY?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "easy_rock_stations" (
"branding" text,
"callsign" text,
"frequency" text,
"power_k_w" text,
"location" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which frequency is DYMY?`:
```sql
|
SELECT "frequency" FROM "table1_23915973_1" WHERE "branding"='106.3 Energy FM Naga'; |
## Task
Generate a SQL query to answer the following question:
`What is the frequency when radio station branding is 106.3 energy fm naga?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23915973_1" (
"branding" text,
"callsign" text,
"frequency" text,
"power_k_w" text,
"coverage" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the frequency when radio station branding is 106.3 energy fm naga?`:
```sql
|
SELECT "callsign" FROM "table1_23915973_1" WHERE "power_k_w"='25kW'; |
## Task
Generate a SQL query to answer the following question:
`What is the callsign when power kw is 25kw?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23915973_1" (
"branding" text,
"callsign" text,
"frequency" text,
"power_k_w" text,
"coverage" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the callsign when power kw is 25kw?`:
```sql
|
SELECT "frequency" FROM "table1_23915973_1" WHERE "callsign"='DXRU-FM'; |
## Task
Generate a SQL query to answer the following question:
`What is the frequency when callsign is dxru-fm?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23915973_1" (
"branding" text,
"callsign" text,
"frequency" text,
"power_k_w" text,
"coverage" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the frequency when callsign is dxru-fm?`:
```sql
|
SELECT "branding" FROM "table1_23915973_1" WHERE "power_k_w"='5kW'; |
## Task
Generate a SQL query to answer the following question:
`What is the radio station branding when the power km is 5kw?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23915973_1" (
"branding" text,
"callsign" text,
"frequency" text,
"power_k_w" text,
"coverage" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the radio station branding when the power km is 5kw?`:
```sql
|
SELECT "coverage" FROM "table1_23915973_1" WHERE "power_k_w"='25kW'; |
## Task
Generate a SQL query to answer the following question:
`What is the coverage when power kw is 25kw?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23915973_1" (
"branding" text,
"callsign" text,
"frequency" text,
"power_k_w" text,
"coverage" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the coverage when power kw is 25kw?`:
```sql
|
SELECT COUNT("power_k_w") FROM "table1_23915973_1" WHERE "frequency"='93.7 MHz'; |
## Task
Generate a SQL query to answer the following question:
`How many power kw have a frequency of 93.7 mhz?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23915973_1" (
"branding" text,
"callsign" text,
"frequency" text,
"power_k_w" text,
"coverage" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many power kw have a frequency of 93.7 mhz?`:
```sql
|
SELECT "written_by" FROM "table1_23918997_1" WHERE "u_s_viewers_million"='0.97'; |
## Task
Generate a SQL query to answer the following question:
`Who were all the writers whose episodes had 0.97 million viewers?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23918997_1" (
"no" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text,
"production_code" text,
"u_s_viewers_million" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who were all the writers whose episodes had 0.97 million viewers?`:
```sql
|
SELECT COUNT("directed_by") FROM "table1_23918997_1" WHERE "written_by"='Brent Fletcher & Miranda Kwok'; |
## Task
Generate a SQL query to answer the following question:
`How many directors worked on the episode written by Brent Fletcher & Miranda Kwok?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23918997_1" (
"no" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text,
"production_code" text,
"u_s_viewers_million" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many directors worked on the episode written by Brent Fletcher & Miranda Kwok?`:
```sql
|
SELECT "title" FROM "table1_23918997_1" WHERE "directed_by"='Rowan Woods'; |
## Task
Generate a SQL query to answer the following question:
`What was the title of the episode directed by Rowan Woods?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23918997_1" (
"no" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text,
"production_code" text,
"u_s_viewers_million" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the title of the episode directed by Rowan Woods?`:
```sql
|
SELECT COUNT("no") FROM "table1_23918997_1" WHERE "u_s_viewers_million"='1.29'; |
## Task
Generate a SQL query to answer the following question:
`How many episodes were viewed by 1.29 million people?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23918997_1" (
"no" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text,
"production_code" text,
"u_s_viewers_million" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many episodes were viewed by 1.29 million people?`:
```sql
|
SELECT "written_by" FROM "table1_23916272_6" WHERE "original_air_date"='March 1, 2004'; |
## Task
Generate a SQL query to answer the following question:
`Who was the writer for the episode originally airing on March 1, 2004?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23916272_6" (
"series_num" real,
"season_num" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the writer for the episode originally airing on March 1, 2004?`:
```sql
|
SELECT "title" FROM "table1_23916272_6" WHERE "season_num"=8; |
## Task
Generate a SQL query to answer the following question:
`List the title for the season episode number of 8.`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23916272_6" (
"series_num" real,
"season_num" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text
);
### SQL
Given the database schema, here is the SQL query that answers `List the title for the season episode number of 8.`:
```sql
|
SELECT "directed_by" FROM "table1_23916272_6" WHERE "title"='\"Out with the Old, in with the New\"'; |
## Task
Generate a SQL query to answer the following question:
`Who directed the "Out with the Old, in with the new" episode?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23916272_6" (
"series_num" real,
"season_num" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who directed the "Out with the Old, in with the new" episode?`:
```sql
|
SELECT "directed_by" FROM "table1_23916272_6" WHERE "original_air_date"='September 29, 2003'; |
## Task
Generate a SQL query to answer the following question:
`Who was the director for the episode originally airing September 29, 2003?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23916272_6" (
"series_num" real,
"season_num" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the director for the episode originally airing September 29, 2003?`:
```sql
|
SELECT MAX("series_num") FROM "table1_23916272_6" WHERE "title"='\"Til Death Do Us Part-And Make It Soon\"'; |
## Task
Generate a SQL query to answer the following question:
`What is the highest series number of the episode "Til Death do us part-and make it soon"?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23916272_6" (
"series_num" real,
"season_num" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest series number of the episode "Til Death do us part-and make it soon"?`:
```sql
|
SELECT "original_air_date" FROM "table1_23937219_2" WHERE "written_by"='Harry Hannigan' AND "directed_by"='Adam Weissman'; |
## Task
Generate a SQL query to answer the following question:
`Name the original air date for harry hannigan directed by adam weissman`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23937219_2" (
"series_num" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text,
"prod_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `Name the original air date for harry hannigan directed by adam weissman`:
```sql
|
SELECT COUNT("directed_by") FROM "table1_23937219_3" WHERE "title"='\"Through The Looking Glass\"'; |
## Task
Generate a SQL query to answer the following question:
`How many people directed "through the looking glass"?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23937219_3" (
"series_num" real,
"season_num" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text,
"prod_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many people directed "through the looking glass"?`:
```sql
|
SELECT COUNT("directed_by") FROM "table1_23937219_3" WHERE "season_num"=7; |
## Task
Generate a SQL query to answer the following question:
`How many people directed episode 7 In the season?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23937219_3" (
"series_num" real,
"season_num" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text,
"prod_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many people directed episode 7 In the season?`:
```sql
|
SELECT COUNT("original_air_date") FROM "table1_23937219_3" WHERE "prod_code"=212; |
## Task
Generate a SQL query to answer the following question:
`How many original air dates were there for the episode with production code 212?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23937219_3" (
"series_num" real,
"season_num" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text,
"prod_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many original air dates were there for the episode with production code 212?`:
```sql
|
SELECT "prod_code" FROM "table1_23937219_3" WHERE "title"='\"Road Trip (aka \"The Kiss\")\"'; |
## Task
Generate a SQL query to answer the following question:
`What is the production code for "road trip (aka "the kiss")"?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23937219_3" (
"series_num" real,
"season_num" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text,
"prod_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the production code for "road trip (aka "the kiss")"?`:
```sql
|
SELECT MIN("prod_code") FROM "table1_23937219_3" WHERE "series_num"=31; |
## Task
Generate a SQL query to answer the following question:
`What is the production code for episode 31 in the series?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23937219_3" (
"series_num" real,
"season_num" real,
"title" text,
"directed_by" text,
"written_by" text,
"original_air_date" text,
"prod_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the production code for episode 31 in the series?`:
```sql
|
SELECT COUNT("season") FROM "table1_23927423_4" WHERE "relegated_from_league"='Barking Birmingham & Solihull Stourbridge'; |
## Task
Generate a SQL query to answer the following question:
`How many seasons did Barking Birmingham & Solihull Stourbridge were relegated from league?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23927423_4" (
"season" text,
"name" text,
"teams" real,
"relegated_to_league" text,
"promoted_to_league" text,
"promoted_from_league" text,
"relegated_from_league" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many seasons did Barking Birmingham & Solihull Stourbridge were relegated from league?`:
```sql
|
SELECT "relegated_to_league" FROM "table1_23927423_4" WHERE "relegated_from_league"='Barking Birmingham & Solihull Stourbridge'; |
## Task
Generate a SQL query to answer the following question:
`Who was relegated to league if Barking Birmingham & Solihull Stourbridge were relegated from league?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23927423_4" (
"season" text,
"name" text,
"teams" real,
"relegated_to_league" text,
"promoted_to_league" text,
"promoted_from_league" text,
"relegated_from_league" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was relegated to league if Barking Birmingham & Solihull Stourbridge were relegated from league?`:
```sql
|
SELECT MIN("teams") FROM "table1_23927423_4"; |
## Task
Generate a SQL query to answer the following question:
`How many were the minimum team that participated in the league?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23927423_4" (
"season" text,
"name" text,
"teams" real,
"relegated_to_league" text,
"promoted_to_league" text,
"promoted_from_league" text,
"relegated_from_league" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many were the minimum team that participated in the league?`:
```sql
|
SELECT MAX("teams") FROM "table1_23927423_4" WHERE "relegated_to_league"='Cornish All Blacks Pertemps Bees'; |
## Task
Generate a SQL query to answer the following question:
`How many teams participated (maximum) when Cornish All Blacks Pertemps Bees were relegated to the league?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23927423_4" (
"season" text,
"name" text,
"teams" real,
"relegated_to_league" text,
"promoted_to_league" text,
"promoted_from_league" text,
"relegated_from_league" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many teams participated (maximum) when Cornish All Blacks Pertemps Bees were relegated to the league?`:
```sql
|
SELECT "promoted_to_league" FROM "table1_23927423_4" WHERE "relegated_to_league"='Coventry'; |
## Task
Generate a SQL query to answer the following question:
`Who was promoted to the league when Coventry was relegated to the league?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23927423_4" (
"season" text,
"name" text,
"teams" real,
"relegated_to_league" text,
"promoted_to_league" text,
"promoted_from_league" text,
"relegated_from_league" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was promoted to the league when Coventry was relegated to the league?`:
```sql
|
SELECT COUNT("promoted_from_league") FROM "table1_23927423_4" WHERE "relegated_to_league"='Esher'; |
## Task
Generate a SQL query to answer the following question:
`How many were promoted from the league when Esher was relegated to the league?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "table1_23927423_4" (
"season" text,
"name" text,
"teams" real,
"relegated_to_league" text,
"promoted_to_league" text,
"promoted_from_league" text,
"relegated_from_league" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many were promoted from the league when Esher was relegated to the league?`:
```sql
|
SELECT MIN("08_09_gp_jgp_2nd") FROM "ice_dancing" WHERE "ws_points"=3197; |
## Task
Generate a SQL query to answer the following question:
`What is the smallest 08-09 GP/JGP 2nd value when WS points equals 3197?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ice_dancing" (
"rank" real,
"ws_points" real,
"name" text,
"country" text,
"08_09_i_o_best" real,
"08_09_gp_jgp_best" real,
"08_09_gp_jgp_2nd" real,
"08_09_oi_best" real,
"08_09_oi_2nd" real,
"07_08_i_o_best" real,
"07_08_gp_jgp_best" real,
"07_08_gp_jgp_2nd" real,
"07_08_oi_best" real,
"07_08_oi_2nd" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the smallest 08-09 GP/JGP 2nd value when WS points equals 3197?`:
```sql
|
SELECT COUNT("07_08_oi_best") FROM "ice_dancing" WHERE "08_09_i_o_best"=202; |
## Task
Generate a SQL query to answer the following question:
`What is the number of 07-08 oi best values associated with 08-09 i/o bests of exactly 202?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ice_dancing" (
"rank" real,
"ws_points" real,
"name" text,
"country" text,
"08_09_i_o_best" real,
"08_09_gp_jgp_best" real,
"08_09_gp_jgp_2nd" real,
"08_09_oi_best" real,
"08_09_oi_2nd" real,
"07_08_i_o_best" real,
"07_08_gp_jgp_best" real,
"07_08_gp_jgp_2nd" real,
"07_08_oi_best" real,
"07_08_oi_2nd" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the number of 07-08 oi best values associated with 08-09 i/o bests of exactly 202?`:
```sql
|
SELECT MIN("07_08_oi_best") FROM "ice_dancing"; |
## Task
Generate a SQL query to answer the following question:
`What is the smallest 07-08 oi best value?`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "ice_dancing" (
"rank" real,
"ws_points" real,
"name" text,
"country" text,
"08_09_i_o_best" real,
"08_09_gp_jgp_best" real,
"08_09_gp_jgp_2nd" real,
"08_09_oi_best" real,
"08_09_oi_2nd" real,
"07_08_i_o_best" real,
"07_08_gp_jgp_best" real,
"07_08_gp_jgp_2nd" real,
"07_08_oi_best" real,
"07_08_oi_2nd" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the smallest 07-08 oi best value?`:
```sql
|
SELECT COUNT("partner") FROM "doubles_7_2_titles_5_runners_up" WHERE "score"='5-7, 6-7 (5-7)'; |
## Task
Generate a SQL query to answer the following question:
`Name the number of partners for 5-7, 6-7 (5-7)`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "doubles_7_2_titles_5_runners_up" (
"outcome" text,
"year" real,
"championship" text,
"surface" text,
"partner" text,
"opponents" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the number of partners for 5-7, 6-7 (5-7)`:
```sql
|
SELECT "surface" FROM "doubles_7_2_titles_5_runners_up" WHERE "opponents"='Cara Black Rennae Stubbs'; |
## Task
Generate a SQL query to answer the following question:
`Name the surface for cara black rennae stubbs`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "doubles_7_2_titles_5_runners_up" (
"outcome" text,
"year" real,
"championship" text,
"surface" text,
"partner" text,
"opponents" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the surface for cara black rennae stubbs`:
```sql
|
SELECT "score" FROM "doubles_7_2_titles_5_runners_up" WHERE "championship"='San Diego'; |
## Task
Generate a SQL query to answer the following question:
`Name the score for san diego`
### Database Schema
This query will run on a database whose schema is represented in this string:
CREATE TABLE "doubles_7_2_titles_5_runners_up" (
"outcome" text,
"year" real,
"championship" text,
"surface" text,
"partner" text,
"opponents" text,
"score" text
);
### SQL
Given the database schema, here is the SQL query that answers `Name the score for san diego`:
```sql
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.