cfahlgren1/wiki_sql_pg_converted huggingface dataset:
## Task
Generate a SQL query to answer the following question:
`What is the main date when the round is third round qualifying?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "calendar" (
  "round" text,
  "main_date" text,
  "number_of_fixtures" real,
  "clubs" text,
  "new_entries_this_round" text,
  "prize_money" text,
  "player_of_the_round" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the main date when the round is third round qualifying?`:
```sql
                SELECT "main_date" FROM "calendar" WHERE "round"='Third Round Qualifying';
```
## Task
Generate a SQL query to answer the following question:
`What is the round when the prize money is £7,500?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "calendar" (
  "round" text,
  "main_date" text,
  "number_of_fixtures" real,
  "clubs" text,
  "new_entries_this_round" text,
  "prize_money" text,
  "player_of_the_round" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the round when the prize money is £7,500?`:
```sql
                SELECT "round" FROM "calendar" WHERE "prize_money"='£7,500';
```
## Task
Generate a SQL query to answer the following question:
`What number in series was the episode written by Eric Gilliland?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27987768_1" (
  "no_in_series" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `What number in series was the episode written by Eric Gilliland?`:
```sql
                SELECT MAX("no_in_series") FROM "table1_27987768_1" WHERE "written_by"='Eric Gilliland';
```
## Task
Generate a SQL query to answer the following question:
`how many total number of points margin when brive is the winners`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "aggregate_results" (
  "winners" text,
  "match_points" text,
  "aggregate_score" text,
  "points_margin" real,
  "losers" text
);
### SQL
Given the database schema, here is the SQL query that answers `how many total number of points margin when brive is the winners`:
```sql
                SELECT COUNT("points_margin") FROM "aggregate_results" WHERE "winners"='Brive';
```
## Task
Generate a SQL query to answer the following question:
`how many match points did gran parma lost`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "aggregate_results" (
  "winners" text,
  "match_points" text,
  "aggregate_score" text,
  "points_margin" real,
  "losers" text
);
### SQL
Given the database schema, here is the SQL query that answers `how many match points did gran parma lost`:
```sql
                SELECT "match_points" FROM "aggregate_results" WHERE "losers"='Gran Parma';
```
## Task
Generate a SQL query to answer the following question:
`how many match points rotherham lose`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "aggregate_results" (
  "winners" text,
  "match_points" text,
  "aggregate_score" text,
  "points_margin" real,
  "losers" text
);
### SQL
Given the database schema, here is the SQL query that answers `how many match points rotherham lose`:
```sql
                SELECT "match_points" FROM "aggregate_results" WHERE "losers"='Rotherham';
```
## Task
Generate a SQL query to answer the following question:
`When brive is the proceed to quarter final how many were eliminated from competition? `

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "aggregate_results" (
  "proceed_to_quarter_final" text,
  "match_points" text,
  "aggregate_score" text,
  "points_margin" real,
  "eliminated_from_competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `When brive is the proceed to quarter final how many were eliminated from competition? `:
```sql
                SELECT COUNT("eliminated_from_competition") FROM "aggregate_results" WHERE "proceed_to_quarter_final"='Brive';
```
## Task
Generate a SQL query to answer the following question:
`When london irish was eliminated from competition who proceeded to quarter final?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "aggregate_results" (
  "proceed_to_quarter_final" text,
  "match_points" text,
  "aggregate_score" text,
  "points_margin" real,
  "eliminated_from_competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `When london irish was eliminated from competition who proceeded to quarter final?`:
```sql
                SELECT "proceed_to_quarter_final" FROM "aggregate_results" WHERE "eliminated_from_competition"='London Irish';
```
## Task
Generate a SQL query to answer the following question:
`When brive proceeded to quarter final what were the match points?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "aggregate_results" (
  "proceed_to_quarter_final" text,
  "match_points" text,
  "aggregate_score" text,
  "points_margin" real,
  "eliminated_from_competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `When brive proceeded to quarter final what were the match points?`:
```sql
                SELECT "match_points" FROM "aggregate_results" WHERE "proceed_to_quarter_final"='Brive';
```
## Task
Generate a SQL query to answer the following question:
`What is the production code of the episode written by Jeff Filgo?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27988281_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the production code of the episode written by Jeff Filgo?`:
```sql
                SELECT MAX("production_code") FROM "table1_27988281_1" WHERE "written_by"='Jeff Filgo';
```
## Task
Generate a SQL query to answer the following question:
`Who wrote the episode titled "Red's Birthday"?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27988281_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `Who wrote the episode titled "Red's Birthday"?`:
```sql
                SELECT "written_by" FROM "table1_27988281_1" WHERE "title"='\"Red''s Birthday\"';
```
## Task
Generate a SQL query to answer the following question:
`What is the production code of the episode titled "Halloween"? `

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27988281_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the production code of the episode titled "Halloween"? `:
```sql
                SELECT MIN("production_code") FROM "table1_27988281_1" WHERE "title"='\"Halloween\"';
```
## Task
Generate a SQL query to answer the following question:
`Name the original air date for bryan moore & chris peterson`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27988408_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `Name the original air date for bryan moore & chris peterson`:
```sql
                SELECT "original_air_date" FROM "table1_27988408_1" WHERE "written_by"='Bryan Moore & Chris Peterson';
```
## Task
Generate a SQL query to answer the following question:
`Name the least production code for  bryan moore & chris peterson`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27988408_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `Name the least production code for  bryan moore & chris peterson`:
```sql
                SELECT MIN("production_code") FROM "table1_27988408_1" WHERE "written_by"='Bryan Moore & Chris Peterson';
```
## Task
Generate a SQL query to answer the following question:
`Name who directed the episode "babe i'm gonna leave you"`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27988408_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `Name who directed the episode "babe i'm gonna leave you"`:
```sql
                SELECT "directed_by" FROM "table1_27988408_1" WHERE "title"='\"Babe I''m Gonna Leave You\"';
```
## Task
Generate a SQL query to answer the following question:
`Name the total number in season for "the battle of evermore"`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27988408_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `Name the total number in season for "the battle of evermore"`:
```sql
                SELECT COUNT("no_in_season") FROM "table1_27988408_1" WHERE "title"='\"The Battle of Evermore\"';
```
## Task
Generate a SQL query to answer the following question:
`How many dates did the episode with a production code of 804 originally air on?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27988559_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many dates did the episode with a production code of 804 originally air on?`:
```sql
                SELECT COUNT("original_air_date") FROM "table1_27988559_1" WHERE "production_code"=804;
```
## Task
Generate a SQL query to answer the following question:
`What is the original air date for "killer queen"?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27988559_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the original air date for "killer queen"?`:
```sql
                SELECT "original_air_date" FROM "table1_27988559_1" WHERE "title"='\"Killer Queen\"';
```
## Task
Generate a SQL query to answer the following question:
`Who directed episode 2 of the season?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27988559_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `Who directed episode 2 of the season?`:
```sql
                SELECT "directed_by" FROM "table1_27988559_1" WHERE "no_in_season"=2;
```
## Task
Generate a SQL query to answer the following question:
`Who wrote "bohemian rhapsody"?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27988559_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `Who wrote "bohemian rhapsody"?`:
```sql
                SELECT "written_by" FROM "table1_27988559_1" WHERE "title"='\"Bohemian Rhapsody\"';
```
## Task
Generate a SQL query to answer the following question:
`What dat did episode 195 in the series originally air?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27988559_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `What dat did episode 195 in the series originally air?`:
```sql
                SELECT "original_air_date" FROM "table1_27988559_1" WHERE "no_in_series"=195;
```
## Task
Generate a SQL query to answer the following question:
`What is the name of episode 5 in the season?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27988540_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the name of episode 5 in the season?`:
```sql
                SELECT "title" FROM "table1_27988540_1" WHERE "no_in_season"=5;
```
## Task
Generate a SQL query to answer the following question:
`Who wrote "it's only rock and roll"?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27988540_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `Who wrote "it's only rock and roll"?`:
```sql
                SELECT "written_by" FROM "table1_27988540_1" WHERE "title"='\"It''s Only Rock and Roll\"';
```
## Task
Generate a SQL query to answer the following question:
`What is the title of episode 155 in the series?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27988540_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the title of episode 155 in the series?`:
```sql
                SELECT "title" FROM "table1_27988540_1" WHERE "no_in_series"=155;
```
## Task
Generate a SQL query to answer the following question:
`What is the last year a sponsorship ended?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_28005160_2" (
  "sponsored_name" text,
  "non_sponsored_name" text,
  "sponsor" text,
  "stadium" text,
  "city" text,
  "country" text,
  "sport" text,
  "sponsorship_ended" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the last year a sponsorship ended?`:
```sql
                SELECT MAX("sponsorship_ended") FROM "table1_28005160_2";
```
## Task
Generate a SQL query to answer the following question:
`How many countries played in the city of ljungskile?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_28005160_2" (
  "sponsored_name" text,
  "non_sponsored_name" text,
  "sponsor" text,
  "stadium" text,
  "city" text,
  "country" text,
  "sport" text,
  "sponsorship_ended" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many countries played in the city of ljungskile?`:
```sql
                SELECT COUNT("country") FROM "table1_28005160_2" WHERE "city"='Ljungskile';
```
## Task
Generate a SQL query to answer the following question:
`What cities are in sweden on this list?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_28005160_2" (
  "sponsored_name" text,
  "non_sponsored_name" text,
  "sponsor" text,
  "stadium" text,
  "city" text,
  "country" text,
  "sport" text,
  "sponsorship_ended" real
);
### SQL
Given the database schema, here is the SQL query that answers `What cities are in sweden on this list?`:
```sql
                SELECT "city" FROM "table1_28005160_2" WHERE "country"='Sweden';
```
## Task
Generate a SQL query to answer the following question:
`What country is new orleans in?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_28005160_2" (
  "sponsored_name" text,
  "non_sponsored_name" text,
  "sponsor" text,
  "stadium" text,
  "city" text,
  "country" text,
  "sport" text,
  "sponsorship_ended" real
);
### SQL
Given the database schema, here is the SQL query that answers `What country is new orleans in?`:
```sql
                SELECT "country" FROM "table1_28005160_2" WHERE "city"='New Orleans';
```
## Task
Generate a SQL query to answer the following question:
`What country are the new orleans shell shockers from?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_28005160_2" (
  "sponsored_name" text,
  "non_sponsored_name" text,
  "sponsor" text,
  "stadium" text,
  "city" text,
  "country" text,
  "sport" text,
  "sponsorship_ended" real
);
### SQL
Given the database schema, here is the SQL query that answers `What country are the new orleans shell shockers from?`:
```sql
                SELECT "country" FROM "table1_28005160_2" WHERE "sponsored_name"='New Orleans Shell Shockers';
```
## Task
Generate a SQL query to answer the following question:
`What is the arrangement for bets3ab 3alia nafsy?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "track_listing" (
  "no" real,
  "title" text,
  "lyricist" text,
  "composer" text,
  "arrangement" text,
  "sound_engineer" text,
  "length" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the arrangement for bets3ab 3alia nafsy?`:
```sql
                SELECT "arrangement" FROM "track_listing" WHERE "title"='Bets3ab 3alia Nafsy';
```
## Task
Generate a SQL query to answer the following question:
`Who was the composer of ain shams?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "track_listing" (
  "no" real,
  "title" text,
  "lyricist" text,
  "composer" text,
  "arrangement" text,
  "sound_engineer" text,
  "length" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the composer of ain shams?`:
```sql
                SELECT "composer" FROM "track_listing" WHERE "title"='Ain Shams';
```
## Task
Generate a SQL query to answer the following question:
`How many numbers are there for kam wa7ed fina?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "track_listing" (
  "no" real,
  "title" text,
  "lyricist" text,
  "composer" text,
  "arrangement" text,
  "sound_engineer" text,
  "length" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many numbers are there for kam wa7ed fina?`:
```sql
                SELECT COUNT("no") FROM "track_listing" WHERE "title"='Kam Wa7ed Fina';
```
## Task
Generate a SQL query to answer the following question:
`Who was the composer of te3rafy?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "track_listing" (
  "no" real,
  "title" text,
  "lyricist" text,
  "composer" text,
  "arrangement" text,
  "sound_engineer" text,
  "length" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the composer of te3rafy?`:
```sql
                SELECT "composer" FROM "track_listing" WHERE "title"='Te3rafy';
```
## Task
Generate a SQL query to answer the following question:
`How many sound engineers were there for law hakon '3er leek?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "track_listing" (
  "no" real,
  "title" text,
  "lyricist" text,
  "composer" text,
  "arrangement" text,
  "sound_engineer" text,
  "length" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many sound engineers were there for law hakon '3er leek?`:
```sql
                SELECT COUNT("sound_engineer") FROM "track_listing" WHERE "title"='Law Hakon ''3er Leek';
```
## Task
Generate a SQL query to answer the following question:
`Which number was the lyricist  ahmed metwally?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "track_listing" (
  "no" real,
  "title" text,
  "lyricist" text,
  "composer" text,
  "arrangement" text,
  "sound_engineer" text,
  "length" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which number was the lyricist  ahmed metwally?`:
```sql
                SELECT "no" FROM "track_listing" WHERE "lyricist"='Ahmed Metwally';
```
## Task
Generate a SQL query to answer the following question:
`What was the site of the game that had an 11-4 score?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "schedule" (
  "num" real,
  "date" text,
  "opponent" text,
  "site_stadium" text,
  "score" text,
  "win" text,
  "loss" text,
  "save" text,
  "attendance" real,
  "overall_record" text,
  "ncaat_record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the site of the game that had an 11-4 score?`:
```sql
                SELECT "site_stadium" FROM "schedule" WHERE "score"='11-4';
```
## Task
Generate a SQL query to answer the following question:
`What was the NCAA Tournament record after the June 26 game?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "schedule" (
  "num" real,
  "date" text,
  "opponent" text,
  "site_stadium" text,
  "score" text,
  "win" text,
  "loss" text,
  "save" text,
  "attendance" real,
  "overall_record" text,
  "ncaat_record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the NCAA Tournament record after the June 26 game?`:
```sql
                SELECT "ncaat_record" FROM "schedule" WHERE "date"='June 26';
```
## Task
Generate a SQL query to answer the following question:
`Who had the save in the game in which Duke (3-2) took the loss?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "schedule" (
  "num" real,
  "date" text,
  "opponent" text,
  "site_stadium" text,
  "score" text,
  "win" text,
  "loss" text,
  "save" text,
  "attendance" real,
  "overall_record" text,
  "ncaat_record" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who had the save in the game in which Duke (3-2) took the loss?`:
```sql
                SELECT "save" FROM "schedule" WHERE "loss"='Duke (3-2)';
```
## Task
Generate a SQL query to answer the following question:
`How many event dates occurred when event details were women's sabre?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "schedule" (
  "event_date" text,
  "event_day" text,
  "approx_duration" text,
  "starting_time" text,
  "event_details" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many event dates occurred when event details were women's sabre?`:
```sql
                SELECT COUNT("event_date") FROM "schedule" WHERE "event_details"='Women''s Sabre';
```
## Task
Generate a SQL query to answer the following question:
`What is every value for approximate duration when event details is women's foil?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "schedule" (
  "event_date" text,
  "event_day" text,
  "approx_duration" text,
  "starting_time" text,
  "event_details" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is every value for approximate duration when event details is women's foil?`:
```sql
                SELECT "approx_duration" FROM "schedule" WHERE "event_details"='Women''s Foil';
```
## Task
Generate a SQL query to answer the following question:
`What is every event date on Sunday with a starting time of 9:30 am?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "schedule" (
  "event_date" text,
  "event_day" text,
  "approx_duration" text,
  "starting_time" text,
  "event_details" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is every event date on Sunday with a starting time of 9:30 am?`:
```sql
                SELECT "event_date" FROM "schedule" WHERE "event_day"='Sunday' AND "starting_time"='9:30 am';
```
## Task
Generate a SQL query to answer the following question:
`How many items appear in the viewers column when the draw is 2?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27994983_8" (
  "draw" real,
  "artist" text,
  "song_english_translation" text,
  "lyrics_l_music_m" text,
  "juries" real,
  "viewers" real,
  "total" real,
  "place" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many items appear in the viewers column when the draw is 2?`:
```sql
                SELECT COUNT("viewers") FROM "table1_27994983_8" WHERE "draw"=2;
```
## Task
Generate a SQL query to answer the following question:
`How many viewers are the when the draw is 3?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27994983_8" (
  "draw" real,
  "artist" text,
  "song_english_translation" text,
  "lyrics_l_music_m" text,
  "juries" real,
  "viewers" real,
  "total" real,
  "place" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many viewers are the when the draw is 3?`:
```sql
                SELECT MAX("viewers") FROM "table1_27994983_8" WHERE "draw"=3;
```
## Task
Generate a SQL query to answer the following question:
`How many juries are there when the draw is 3?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27994983_8" (
  "draw" real,
  "artist" text,
  "song_english_translation" text,
  "lyrics_l_music_m" text,
  "juries" real,
  "viewers" real,
  "total" real,
  "place" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many juries are there when the draw is 3?`:
```sql
                SELECT MAX("juries") FROM "table1_27994983_8" WHERE "draw"=3;
```
## Task
Generate a SQL query to answer the following question:
`How many juries are there for Brolle?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_27994983_8" (
  "draw" real,
  "artist" text,
  "song_english_translation" text,
  "lyrics_l_music_m" text,
  "juries" real,
  "viewers" real,
  "total" real,
  "place" real
);
### SQL
Given the database schema, here is the SQL query that answers `How many juries are there for Brolle?`:
```sql
                SELECT MAX("juries") FROM "table1_27994983_8" WHERE "artist"='Brolle';
```
## Task
Generate a SQL query to answer the following question:
`What are the former counties of the Great Grimsby district?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "former_districts" (
  "district" text,
  "status" text,
  "date_abolished" text,
  "former_county" text,
  "successor" text
);
### SQL
Given the database schema, here is the SQL query that answers `What are the former counties of the Great Grimsby district?`:
```sql
                SELECT "former_county" FROM "former_districts" WHERE "district"='Great Grimsby';
```
## Task
Generate a SQL query to answer the following question:
`How many statuses are there for the Durham district?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "former_districts" (
  "district" text,
  "status" text,
  "date_abolished" text,
  "former_county" text,
  "successor" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many statuses are there for the Durham district?`:
```sql
                SELECT COUNT("status") FROM "former_districts" WHERE "district"='Durham';
```
## Task
Generate a SQL query to answer the following question:
`What are the statuses of the districts whose successor is Wiltshire?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "former_districts" (
  "district" text,
  "status" text,
  "date_abolished" text,
  "former_county" text,
  "successor" text
);
### SQL
Given the database schema, here is the SQL query that answers `What are the statuses of the districts whose successor is Wiltshire?`:
```sql
                SELECT "status" FROM "former_districts" WHERE "successor"='Wiltshire';
```
## Task
Generate a SQL query to answer the following question:
`What is the SDLP of Belfast?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "by_council" (
  "council" text,
  "tuv" real,
  "democratic_unionist" real,
  "ulster_unionist" real,
  "alliance" real,
  "sdlp" real,
  "sinn_f_in" real,
  "green_ni" real,
  "independent" real,
  "others" text,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the SDLP of Belfast?`:
```sql
                SELECT MAX("sdlp") FROM "by_council" WHERE "council"='Belfast';
```
## Task
Generate a SQL query to answer the following question:
`What is the smallest Alliance where the total is 25?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "by_council" (
  "council" text,
  "tuv" real,
  "democratic_unionist" real,
  "ulster_unionist" real,
  "alliance" real,
  "sdlp" real,
  "sinn_f_in" real,
  "green_ni" real,
  "independent" real,
  "others" text,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the smallest Alliance where the total is 25?`:
```sql
                SELECT MIN("alliance") FROM "by_council" WHERE "total"=25;
```
## Task
Generate a SQL query to answer the following question:
`Who wrote the episode that 2.93 million viewers?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_28019988_2" (
  "series_num" 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 wrote the episode that 2.93 million viewers?`:
```sql
                SELECT "written_by" FROM "table1_28019988_2" WHERE "u_s_viewers_million"='2.93';
```
## Task
Generate a SQL query to answer the following question:
`What series number is the episode with production code bdf101?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_28019988_2" (
  "series_num" 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 series number is the episode with production code bdf101?`:
```sql
                SELECT MAX("series_num") FROM "table1_28019988_2" WHERE "production_code"='BDF101';
```
## Task
Generate a SQL query to answer the following question:
`What series number is the episode entitled "Booty"?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_28019988_2" (
  "series_num" 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 series number is the episode entitled "Booty"?`:
```sql
                SELECT MAX("series_num") FROM "table1_28019988_2" WHERE "title"='\"Booty\"';
```
## Task
Generate a SQL query to answer the following question:
`What is the series number for the episode with production code bdf109?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_28019988_2" (
  "series_num" 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 is the series number for the episode with production code bdf109?`:
```sql
                SELECT "series_num" FROM "table1_28019988_2" WHERE "production_code"='BDF109';
```
## Task
Generate a SQL query to answer the following question:
`Who directed the episode with the production code of 6AKY11?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_28027307_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" text,
  "u_s_viewers_millions" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who directed the episode with the production code of 6AKY11?`:
```sql
                SELECT "directed_by" FROM "table1_28027307_1" WHERE "production_code"='6AKY11';
```
## Task
Generate a SQL query to answer the following question:
`Who wrote the episode titled "The Feet on the Beach"?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_28027307_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" text,
  "u_s_viewers_millions" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who wrote the episode titled "The Feet on the Beach"?`:
```sql
                SELECT "written_by" FROM "table1_28027307_1" WHERE "title"='\"The Feet on the Beach\"';
```
## Task
Generate a SQL query to answer the following question:
`What number episode in the season was titled "The Blackout in the Blizzard"?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_28027307_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" text,
  "u_s_viewers_millions" text
);
### SQL
Given the database schema, here is the SQL query that answers `What number episode in the season was titled "The Blackout in the Blizzard"?`:
```sql
                SELECT "no_in_season" FROM "table1_28027307_1" WHERE "title"='\"The Blackout in the Blizzard\"';
```
## Task
Generate a SQL query to answer the following question:
`How many millions of U.S. viewers watched the episode with the production code of 6AKY07?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_28027307_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" text,
  "u_s_viewers_millions" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many millions of U.S. viewers watched the episode with the production code of 6AKY07?`:
```sql
                SELECT "u_s_viewers_millions" FROM "table1_28027307_1" WHERE "production_code"='6AKY07';
```
## Task
Generate a SQL query to answer the following question:
`What number episode in the series was watched by 10.96 million U.S. viewers? `

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_28027307_1" (
  "no_in_series" real,
  "no_in_season" real,
  "title" text,
  "directed_by" text,
  "written_by" text,
  "original_air_date" text,
  "production_code" text,
  "u_s_viewers_millions" text
);
### SQL
Given the database schema, here is the SQL query that answers `What number episode in the series was watched by 10.96 million U.S. viewers? `:
```sql
                SELECT MIN("no_in_series") FROM "table1_28027307_1" WHERE "u_s_viewers_millions"='10.96';
```
## Task
Generate a SQL query to answer the following question:
`What dance had a score total of 31?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_2803106_1" (
  "week_num" real,
  "dance_song" text,
  "horwood" text,
  "goodman" text,
  "dixon" text,
  "tonioli" text,
  "total" text,
  "result" text
);
### SQL
Given the database schema, here is the SQL query that answers `What dance had a score total of 31?`:
```sql
                SELECT "dance_song" FROM "table1_2803106_1" WHERE "total"='31';
```
## Task
Generate a SQL query to answer the following question:
`What was the result for the dance that tonioli's scored an 8 and horwood scored a 6?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_2803106_1" (
  "week_num" real,
  "dance_song" text,
  "horwood" text,
  "goodman" text,
  "dixon" text,
  "tonioli" text,
  "total" text,
  "result" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the result for the dance that tonioli's scored an 8 and horwood scored a 6?`:
```sql
                SELECT "result" FROM "table1_2803106_1" WHERE "tonioli"='8' AND "horwood"='6';
```
## Task
Generate a SQL query to answer the following question:
`How many times did tonioli score a 9 when horwood scored a 6?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_2803106_1" (
  "week_num" real,
  "dance_song" text,
  "horwood" text,
  "goodman" text,
  "dixon" text,
  "tonioli" text,
  "total" text,
  "result" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many times did tonioli score a 9 when horwood scored a 6?`:
```sql
                SELECT COUNT("total") FROM "table1_2803106_1" WHERE "tonioli"='9' AND "horwood"='6';
```
## Task
Generate a SQL query to answer the following question:
`On week 11 when Dixon scored an 8, what was tonioli's score?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "table1_2803106_1" (
  "week_num" real,
  "dance_song" text,
  "horwood" text,
  "goodman" text,
  "dixon" text,
  "tonioli" text,
  "total" text,
  "result" text
);
### SQL
Given the database schema, here is the SQL query that answers `On week 11 when Dixon scored an 8, what was tonioli's score?`:
```sql
                SELECT "tonioli" FROM "table1_2803106_1" WHERE "week_num"=11 AND "dixon"='8';
```
## Task
Generate a SQL query to answer the following question:
`How many winners from previous round were there in the semi finals?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "teams" (
  "round" text,
  "clubs_remaining" real,
  "clubs_involved" real,
  "winners_from_previous_round" text,
  "new_entries_this_round" text,
  "leagues_entering_at_this_round" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many winners from previous round were there in the semi finals?`:
```sql
                SELECT "winners_from_previous_round" FROM "teams" WHERE "round"='Semi finals';
```
## Task
Generate a SQL query to answer the following question:
`What was the round that had 32 winners from previous round?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "teams" (
  "round" text,
  "clubs_remaining" real,
  "clubs_involved" real,
  "winners_from_previous_round" text,
  "new_entries_this_round" text,
  "leagues_entering_at_this_round" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the round that had 32 winners from previous round?`:
```sql
                SELECT "round" FROM "teams" WHERE "winners_from_previous_round"='32';
```
## Task
Generate a SQL query to answer the following question:
`How many clubs were remaining in the preliminary round?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "teams" (
  "round" text,
  "clubs_remaining" real,
  "clubs_involved" real,
  "winners_from_previous_round" text,
  "new_entries_this_round" text,
  "leagues_entering_at_this_round" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many clubs were remaining in the preliminary round?`:
```sql
                SELECT "clubs_remaining" FROM "teams" WHERE "round"='Preliminary round';
```
## Task
Generate a SQL query to answer the following question:
`What was the round when there were 16 winners from the previous round?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "teams" (
  "round" text,
  "clubs_remaining" real,
  "clubs_involved" real,
  "winners_from_previous_round" text,
  "new_entries_this_round" text,
  "leagues_entering_at_this_round" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the round when there were 16 winners from the previous round?`:
```sql
                SELECT "round" FROM "teams" WHERE "winners_from_previous_round"='16';
```
## Task
Generate a SQL query to answer the following question:
`How many clubs were involved in the second round?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "teams" (
  "round" text,
  "clubs_remaining" real,
  "clubs_involved" real,
  "winners_from_previous_round" text,
  "new_entries_this_round" text,
  "leagues_entering_at_this_round" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many clubs were involved in the second round?`:
```sql
                SELECT "clubs_involved" FROM "teams" WHERE "round"='Second round';
```
## Task
Generate a SQL query to answer the following question:
`When  grand prix de sar la princesse lalla meryem is the tournament what is the town?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "wta_tour" (
  "week" real,
  "start_date" text,
  "type" text,
  "tournament" text,
  "surface" text,
  "town" text,
  "country" text,
  "continent" text,
  "prize_money" text
);
### SQL
Given the database schema, here is the SQL query that answers `When  grand prix de sar la princesse lalla meryem is the tournament what is the town?`:
```sql
                SELECT "town" FROM "wta_tour" WHERE "tournament"='Grand Prix De SAR La Princesse Lalla Meryem';
```
## Task
Generate a SQL query to answer the following question:
`When stuttgart is the town what is the type?`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "wta_tour" (
  "week" real,
  "start_date" text,
  "type" text,
  "tournament" text,
  "surface" text,
  "town" text,
  "country" text,
  "continent" text,
  "prize_money" text
);
### SQL
Given the database schema, here is the SQL query that answers `When stuttgart is the town what is the type?`:
```sql
                SELECT "type" FROM "wta_tour" WHERE "town"='Stuttgart';
```
## Task
Generate a SQL query to answer the following question:
`who is the person that is part of the belgian vw club that works with frédéric miclotte`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "selected_entries" (
  "entrant" text,
  "constructor" text,
  "car" text,
  "driver" text,
  "co_driver" text,
  "rounds" text
);
### SQL
Given the database schema, here is the SQL query that answers `who is the person that is part of the belgian vw club that works with frédéric miclotte`:
```sql
                SELECT "driver" FROM "selected_entries" WHERE "entrant"='Belgian VW Club' AND "co_driver"='Frédéric Miclotte';
```
## Task
Generate a SQL query to answer the following question:
`what is the type of vehicle driven by mark higgins`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "selected_entries" (
  "entrant" text,
  "constructor" text,
  "car" text,
  "driver" text,
  "co_driver" text,
  "rounds" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the type of vehicle driven by mark higgins`:
```sql
                SELECT "car" FROM "selected_entries" WHERE "driver"='Mark Higgins';
```
## Task
Generate a SQL query to answer the following question:
`what is the entry where the other person is zdeněk hrůza`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "selected_entries" (
  "entrant" text,
  "constructor" text,
  "car" text,
  "driver" text,
  "co_driver" text,
  "rounds" text
);
### SQL
Given the database schema, here is the SQL query that answers `what is the entry where the other person is zdeněk hrůza`:
```sql
                SELECT "entrant" FROM "selected_entries" WHERE "co_driver"='Zdeněk Hrůza';
```
## Task
Generate a SQL query to answer the following question:
`who is the other person where the assistant is paulo babo`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "selected_entries" (
  "entrant" text,
  "constructor" text,
  "car" text,
  "driver" text,
  "co_driver" text,
  "rounds" text
);
### SQL
Given the database schema, here is the SQL query that answers `who is the other person where the assistant is paulo babo`:
```sql
                SELECT "driver" FROM "selected_entries" WHERE "co_driver"='Paulo Babo';
```
## Task
Generate a SQL query to answer the following question:
`what are all the people where the entries is peugeot sport polska`

### Database Schema
This query will run on a database whose schema is represented in this string:

CREATE TABLE "selected_entries" (
  "entrant" text,
  "constructor" text,
  "car" text,
  "driver" text,
  "co_driver" text,
  "rounds" text
);
### SQL
Given the database schema, here is the SQL query that answers `what are all the people where the entries is peugeot sport polska`:
```sql
                SELECT "driver" FROM "selected_entries" WHERE "entrant"='Peugeot Sport Polska';
```