cfahlgren1/wiki_sql_pg_converted huggingface dataset:
## Task
Generate a SQL query to answer the following question:
`What is the lowest number of events a tournament with more than 1 top-10 and more than 0 wins has?`

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

CREATE TABLE "summary" (
  "tournament" text,
  "wins" real,
  "top_10" real,
  "events" real,
  "cuts_made" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest number of events a tournament with more than 1 top-10 and more than 0 wins has?`:
```sql
                SELECT MIN("events") FROM "summary" WHERE "top_10">1 AND "wins">0;
```
## Task
Generate a SQL query to answer the following question:
`How many laps did the 6th placed in 1998 complete?`

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

CREATE TABLE "24_hours_of_le_mans_results" (
  "year" real,
  "team" text,
  "co_drivers" text,
  "class" text,
  "laps" real,
  "pos" text,
  "class_pos" text
);
### SQL
Given the database schema, here is the SQL query that answers `How many laps did the 6th placed in 1998 complete?`:
```sql
                SELECT SUM("laps") FROM "24_hours_of_le_mans_results" WHERE "pos"='6th' AND "year"=1998;
```
## Task
Generate a SQL query to answer the following question:
`What position did the 5th place team after 1992 with over 346 laps finish in?`

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

CREATE TABLE "24_hours_of_le_mans_results" (
  "year" real,
  "team" text,
  "co_drivers" text,
  "class" text,
  "laps" real,
  "pos" text,
  "class_pos" text
);
### SQL
Given the database schema, here is the SQL query that answers `What position did the 5th place team after 1992 with over 346 laps finish in?`:
```sql
                SELECT "pos" FROM "24_hours_of_le_mans_results" WHERE "class_pos"='5th' AND "year">1992 AND "laps">346;
```
## Task
Generate a SQL query to answer the following question:
`What team was c1 class, had over 331 laps after 1990?`

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

CREATE TABLE "24_hours_of_le_mans_results" (
  "year" real,
  "team" text,
  "co_drivers" text,
  "class" text,
  "laps" real,
  "pos" text,
  "class_pos" text
);
### SQL
Given the database schema, here is the SQL query that answers `What team was c1 class, had over 331 laps after 1990?`:
```sql
                SELECT "team" FROM "24_hours_of_le_mans_results" WHERE "class"='c1' AND "laps">331 AND "year">1990;
```
## Task
Generate a SQL query to answer the following question:
`What class did eddie cheever raul boesel race in?`

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

CREATE TABLE "24_hours_of_le_mans_results" (
  "year" real,
  "team" text,
  "co_drivers" text,
  "class" text,
  "laps" real,
  "pos" text,
  "class_pos" text
);
### SQL
Given the database schema, here is the SQL query that answers `What class did eddie cheever raul boesel race in?`:
```sql
                SELECT "class" FROM "24_hours_of_le_mans_results" WHERE "co_drivers"='eddie cheever raul boesel';
```
## Task
Generate a SQL query to answer the following question:
`What's the lowest rank of a player who played in 2012?`

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

CREATE TABLE "wins_over_top_10_players_per_season" (
  "player" text,
  "rank" real,
  "event" text,
  "surface" text,
  "score" text
);
### SQL
Given the database schema, here is the SQL query that answers `What's the lowest rank of a player who played in 2012?`:
```sql
                SELECT MIN("rank") FROM "wins_over_top_10_players_per_season" WHERE "event"='2012';
```
## Task
Generate a SQL query to answer the following question:
`What player has the rank 2011?`

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

CREATE TABLE "wins_over_top_10_players_per_season" (
  "player" text,
  "rank" real,
  "event" text,
  "surface" text,
  "score" text
);
### SQL
Given the database schema, here is the SQL query that answers `What player has the rank 2011?`:
```sql
                SELECT "player" FROM "wins_over_top_10_players_per_season" WHERE "rank"=2011;
```
## Task
Generate a SQL query to answer the following question:
`What was the score of the match played on hard with a person ranked 10?`

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

CREATE TABLE "wins_over_top_10_players_per_season" (
  "player" text,
  "rank" real,
  "event" text,
  "surface" text,
  "score" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the score of the match played on hard with a person ranked 10?`:
```sql
                SELECT "score" FROM "wins_over_top_10_players_per_season" WHERE "surface"='hard' AND "rank"=10;
```
## Task
Generate a SQL query to answer the following question:
`What females speak Romanian?`

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

CREATE TABLE "language" (
  "language" text,
  "number" text,
  "percentage_pct" text,
  "males" text,
  "females" text
);
### SQL
Given the database schema, here is the SQL query that answers `What females speak Romanian?`:
```sql
                SELECT "females" FROM "language" WHERE "language"='romanian';
```
## Task
Generate a SQL query to answer the following question:
`What females have males of 1 234?`

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

CREATE TABLE "language" (
  "language" text,
  "number" text,
  "percentage_pct" text,
  "males" text,
  "females" text
);
### SQL
Given the database schema, here is the SQL query that answers `What females have males of 1 234?`:
```sql
                SELECT "females" FROM "language" WHERE "males"='1 234';
```
## Task
Generate a SQL query to answer the following question:
`What males speak Polish?`

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

CREATE TABLE "language" (
  "language" text,
  "number" text,
  "percentage_pct" text,
  "males" text,
  "females" text
);
### SQL
Given the database schema, here is the SQL query that answers `What males speak Polish?`:
```sql
                SELECT "males" FROM "language" WHERE "language"='polish';
```
## Task
Generate a SQL query to answer the following question:
`What is the number of males 977 948?`

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

CREATE TABLE "language" (
  "language" text,
  "number" text,
  "percentage_pct" text,
  "males" text,
  "females" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the number of males 977 948?`:
```sql
                SELECT "number" FROM "language" WHERE "males"='977 948';
```
## Task
Generate a SQL query to answer the following question:
`Bowler of shane bond has what lowest overall number?`

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

CREATE TABLE "maiden_overs" (
  "bowler" text,
  "over_no" real,
  "venue" text,
  "date" text,
  "wickets" text
);
### SQL
Given the database schema, here is the SQL query that answers `Bowler of shane bond has what lowest overall number?`:
```sql
                SELECT MIN("over_no") FROM "maiden_overs" WHERE "bowler"='shane bond';
```
## Task
Generate a SQL query to answer the following question:
`Wickets of chris gayle caught kapali happened on what date?`

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

CREATE TABLE "maiden_overs" (
  "bowler" text,
  "over_no" real,
  "venue" text,
  "date" text,
  "wickets" text
);
### SQL
Given the database schema, here is the SQL query that answers `Wickets of chris gayle caught kapali happened on what date?`:
```sql
                SELECT "date" FROM "maiden_overs" WHERE "wickets"='chris gayle caught kapali';
```
## Task
Generate a SQL query to answer the following question:
`What is the area of a nation has a population under 44,788,852, and a GDP greater than $83.351 billion?`

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

CREATE TABLE "foundation" (
  "member_countries" text,
  "population" real,
  "area_km" real,
  "gdp_billion_us" real,
  "gdp_per_capita_us" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the area of a nation has a population under 44,788,852, and a GDP greater than $83.351 billion?`:
```sql
                SELECT COUNT("area_km") FROM "foundation" WHERE "gdp_billion_us">83.351 AND "population"<'44,788,852';
```
## Task
Generate a SQL query to answer the following question:
`What is the population of the place that has an area (km²) of 30,528, and a GDP (billion US$) larger than 58.316?`

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

CREATE TABLE "foundation" (
  "member_countries" text,
  "population" real,
  "area_km" real,
  "gdp_billion_us" real,
  "gdp_per_capita_us" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the population of the place that has an area (km²) of 30,528, and a GDP (billion US$) larger than 58.316?`:
```sql
                SELECT SUM("population") FROM "foundation" WHERE "area_km"='30,528' AND "gdp_billion_us">58.316;
```
## Task
Generate a SQL query to answer the following question:
`What is the GDP of the place with over 54,292,038 people and an Area (km²) greater than 30,528?`

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

CREATE TABLE "foundation" (
  "member_countries" text,
  "population" real,
  "area_km" real,
  "gdp_billion_us" real,
  "gdp_per_capita_us" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the GDP of the place with over 54,292,038 people and an Area (km²) greater than 30,528?`:
```sql
                SELECT MIN("gdp_billion_us") FROM "foundation" WHERE "population">'54,292,038' AND "area_km">'30,528';
```
## Task
Generate a SQL query to answer the following question:
`What year did Kyle Newman place third?`

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

CREATE TABLE "british_under_18_champions" (
  "year" real,
  "venue" text,
  "winner" text,
  "runner_up" text,
  "third" text
);
### SQL
Given the database schema, here is the SQL query that answers `What year did Kyle Newman place third?`:
```sql
                SELECT "year" FROM "british_under_18_champions" WHERE "third"='kyle newman';
```
## Task
Generate a SQL query to answer the following question:
`What was the venue when Jerran Hart won?`

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

CREATE TABLE "british_under_18_champions" (
  "year" real,
  "venue" text,
  "winner" text,
  "runner_up" text,
  "third" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the venue when Jerran Hart won?`:
```sql
                SELECT "venue" FROM "british_under_18_champions" WHERE "winner"='jerran hart';
```
## Task
Generate a SQL query to answer the following question:
`Who was the runner-up in 2004?`

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

CREATE TABLE "british_under_18_champions" (
  "year" real,
  "venue" text,
  "winner" text,
  "runner_up" text,
  "third" text
);
### SQL
Given the database schema, here is the SQL query that answers `Who was the runner-up in 2004?`:
```sql
                SELECT "runner_up" FROM "british_under_18_champions" WHERE "year"=2004;
```
## Task
Generate a SQL query to answer the following question:
`What was the venue when Jack Hargreaves finished third?`

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

CREATE TABLE "british_under_18_champions" (
  "year" real,
  "venue" text,
  "winner" text,
  "runner_up" text,
  "third" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the venue when Jack Hargreaves finished third?`:
```sql
                SELECT "venue" FROM "british_under_18_champions" WHERE "third"='jack hargreaves';
```
## Task
Generate a SQL query to answer the following question:
`What was the venue when Ben Barker finished third?`

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

CREATE TABLE "british_under_18_champions" (
  "year" real,
  "venue" text,
  "winner" text,
  "runner_up" text,
  "third" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the venue when Ben Barker finished third?`:
```sql
                SELECT "venue" FROM "british_under_18_champions" WHERE "third"='ben barker';
```
## Task
Generate a SQL query to answer the following question:
`What is on tv at 10:00 on the same channel that had Infoman on at 7:30?`

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

CREATE TABLE "thursday" (
  "7_00" text,
  "7_30" text,
  "8_00" text,
  "8_30" text,
  "9_00" text,
  "9_30" text,
  "10_00" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is on tv at 10:00 on the same channel that had Infoman on at 7:30?`:
```sql
                SELECT "10_00" FROM "thursday" WHERE "7_30"='infoman';
```
## Task
Generate a SQL query to answer the following question:
`What is on tv at 10:00 on the same channel that had movies on at 8:00?`

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

CREATE TABLE "thursday" (
  "7_00" text,
  "7_30" text,
  "8_00" text,
  "8_30" text,
  "9_00" text,
  "9_30" text,
  "10_00" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is on tv at 10:00 on the same channel that had movies on at 8:00?`:
```sql
                SELECT "10_00" FROM "thursday" WHERE "8_00"='movies';
```
## Task
Generate a SQL query to answer the following question:
`What is on tv at 7:00 on the same channel that has Survivor: China on at 8:00?`

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

CREATE TABLE "thursday" (
  "7_00" text,
  "7_30" text,
  "8_00" text,
  "8_30" text,
  "9_00" text,
  "9_30" text,
  "10_00" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is on tv at 7:00 on the same channel that has Survivor: China on at 8:00?`:
```sql
                SELECT "7_00" FROM "thursday" WHERE "8_00"='survivor: china';
```
## Task
Generate a SQL query to answer the following question:
`What is on tv at 8:00 on the same channel that had Loft Story on at 7:00?`

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

CREATE TABLE "thursday" (
  "7_00" text,
  "7_30" text,
  "8_00" text,
  "8_30" text,
  "9_00" text,
  "9_30" text,
  "10_00" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is on tv at 8:00 on the same channel that had Loft Story on at 7:00?`:
```sql
                SELECT "8_00" FROM "thursday" WHERE "7_00"='loft story';
```
## Task
Generate a SQL query to answer the following question:
`What is on tv at 9:30 on the same channel that had e2 on at 7:30?`

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

CREATE TABLE "thursday" (
  "7_00" text,
  "7_30" text,
  "8_00" text,
  "8_30" text,
  "9_00" text,
  "9_30" text,
  "10_00" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is on tv at 9:30 on the same channel that had e2 on at 7:30?`:
```sql
                SELECT "9_30" FROM "thursday" WHERE "7_30"='e2';
```
## Task
Generate a SQL query to answer the following question:
`What province/region is RJTQ located?`

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

CREATE TABLE "domestic" (
  "city" text,
  "province_region" text,
  "country" text,
  "iata" text,
  "icao" text,
  "airport" text
);
### SQL
Given the database schema, here is the SQL query that answers `What province/region is RJTQ located?`:
```sql
                SELECT "province_region" FROM "domestic" WHERE "icao"='rjtq';
```
## Task
Generate a SQL query to answer the following question:
`In what city is RJSN located?`

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

CREATE TABLE "domestic" (
  "city" text,
  "province_region" text,
  "country" text,
  "iata" text,
  "icao" text,
  "airport" text
);
### SQL
Given the database schema, here is the SQL query that answers `In what city is RJSN located?`:
```sql
                SELECT "city" FROM "domestic" WHERE "icao"='rjsn';
```
## Task
Generate a SQL query to answer the following question:
`What is RJCM's IATA?`

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

CREATE TABLE "domestic" (
  "city" text,
  "province_region" text,
  "country" text,
  "iata" text,
  "icao" text,
  "airport" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is RJCM's IATA?`:
```sql
                SELECT "iata" FROM "domestic" WHERE "icao"='rjcm';
```
## Task
Generate a SQL query to answer the following question:
`In what country is Hokkaidō and New Chitose airport located?`

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

CREATE TABLE "domestic" (
  "city" text,
  "province_region" text,
  "country" text,
  "iata" text,
  "icao" text,
  "airport" text
);
### SQL
Given the database schema, here is the SQL query that answers `In what country is Hokkaidō and New Chitose airport located?`:
```sql
                SELECT "country" FROM "domestic" WHERE "province_region"='hokkaidō' AND "airport"='new chitose airport';
```
## Task
Generate a SQL query to answer the following question:
`In what country is Hiroshima Airport located?`

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

CREATE TABLE "domestic" (
  "city" text,
  "province_region" text,
  "country" text,
  "iata" text,
  "icao" text,
  "airport" text
);
### SQL
Given the database schema, here is the SQL query that answers `In what country is Hiroshima Airport located?`:
```sql
                SELECT "country" FROM "domestic" WHERE "airport"='hiroshima airport';
```
## Task
Generate a SQL query to answer the following question:
`What is the ICAO of Nakashibetsu?`

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

CREATE TABLE "domestic" (
  "city" text,
  "province_region" text,
  "country" text,
  "iata" text,
  "icao" text,
  "airport" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the ICAO of Nakashibetsu?`:
```sql
                SELECT "icao" FROM "domestic" WHERE "city"='nakashibetsu';
```
## Task
Generate a SQL query to answer the following question:
`What is the total number of games lost when 22 have been played, the losing BP number is 2, and the club is Merthyr RFC?`

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

CREATE TABLE "2011_2012_table" (
  "club" text,
  "played" text,
  "drawn" text,
  "lost" text,
  "try_bp" text,
  "losing_bp" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total number of games lost when 22 have been played, the losing BP number is 2, and the club is Merthyr RFC?`:
```sql
                SELECT "lost" FROM "2011_2012_table" WHERE "played"='22' AND "losing_bp"='2' AND "club"='merthyr rfc';
```
## Task
Generate a SQL query to answer the following question:
`What is the number drawn when 3 have been lost?`

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

CREATE TABLE "2011_2012_table" (
  "club" text,
  "played" text,
  "drawn" text,
  "lost" text,
  "try_bp" text,
  "losing_bp" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the number drawn when 3 have been lost?`:
```sql
                SELECT "drawn" FROM "2011_2012_table" WHERE "lost"='3';
```
## Task
Generate a SQL query to answer the following question:
`What is the number drawn when the try BP is 1?`

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

CREATE TABLE "2011_2012_table" (
  "club" text,
  "played" text,
  "drawn" text,
  "lost" text,
  "try_bp" text,
  "losing_bp" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the number drawn when the try BP is 1?`:
```sql
                SELECT "drawn" FROM "2011_2012_table" WHERE "try_bp"='1';
```
## Task
Generate a SQL query to answer the following question:
`What is the try BP when the losing BP is 4 and the club is Bargoed RFC?`

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

CREATE TABLE "2011_2012_table" (
  "club" text,
  "played" text,
  "drawn" text,
  "lost" text,
  "try_bp" text,
  "losing_bp" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the try BP when the losing BP is 4 and the club is Bargoed RFC?`:
```sql
                SELECT "try_bp" FROM "2011_2012_table" WHERE "losing_bp"='4' AND "club"='bargoed rfc';
```
## Task
Generate a SQL query to answer the following question:
`What is the club that has played 22 rounds, has a drawn score of 0, has lost 14, and whose losing BP is 5?`

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

CREATE TABLE "2011_2012_table" (
  "club" text,
  "played" text,
  "drawn" text,
  "lost" text,
  "try_bp" text,
  "losing_bp" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the club that has played 22 rounds, has a drawn score of 0, has lost 14, and whose losing BP is 5?`:
```sql
                SELECT "club" FROM "2011_2012_table" WHERE "played"='22' AND "drawn"='0' AND "lost"='14' AND "losing_bp"='5';
```
## Task
Generate a SQL query to answer the following question:
`What average Total has a Rank of 3 and a Bronze award larger than 3?`

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

CREATE TABLE "total" (
  "rank" text,
  "nation" text,
  "gold" real,
  "silver" real,
  "bronze" real,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What average Total has a Rank of 3 and a Bronze award larger than 3?`:
```sql
                SELECT AVG("total") FROM "total" WHERE "rank"='3' AND "bronze">3;
```
## Task
Generate a SQL query to answer the following question:
`What average Total has a Gold award of 13 and a Bronze award less than 13?`

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

CREATE TABLE "total" (
  "rank" text,
  "nation" text,
  "gold" real,
  "silver" real,
  "bronze" real,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What average Total has a Gold award of 13 and a Bronze award less than 13?`:
```sql
                SELECT AVG("total") FROM "total" WHERE "gold"=13 AND "bronze"<13;
```
## Task
Generate a SQL query to answer the following question:
`What is the average Gold award that has a Silver award greater than 2, and a Bronze award less than 13, and a Total greater than 24?`

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

CREATE TABLE "total" (
  "rank" text,
  "nation" text,
  "gold" real,
  "silver" real,
  "bronze" real,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average Gold award that has a Silver award greater than 2, and a Bronze award less than 13, and a Total greater than 24?`:
```sql
                SELECT AVG("gold") FROM "total" WHERE "silver">2 AND "bronze"<13 AND "total">24;
```
## Task
Generate a SQL query to answer the following question:
`What is the record number of the game where Guardado lost?`

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

CREATE TABLE "game_log" (
  "date" text,
  "opponent" text,
  "score" text,
  "loss" text,
  "attendance" real,
  "record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the record number of the game where Guardado lost?`:
```sql
                SELECT "record" FROM "game_log" WHERE "loss"='guardado';
```
## Task
Generate a SQL query to answer the following question:
`What was the lowest attendance recorded at a game on September 28?`

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

CREATE TABLE "game_log" (
  "date" text,
  "opponent" text,
  "score" text,
  "loss" text,
  "attendance" real,
  "record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the lowest attendance recorded at a game on September 28?`:
```sql
                SELECT MIN("attendance") FROM "game_log" WHERE "date"='september 28';
```
## Task
Generate a SQL query to answer the following question:
`What is the average gold that has a total of 2 and more than 1 bronze.`

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

CREATE TABLE "medal_table" (
  "rank" real,
  "nation" text,
  "gold" real,
  "silver" real,
  "bronze" real,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average gold that has a total of 2 and more than 1 bronze.`:
```sql
                SELECT AVG("gold") FROM "medal_table" WHERE "total"=2 AND "bronze">1;
```
## Task
Generate a SQL query to answer the following question:
`What is the 2006 result of the Canada Masters tournament that is A in 2009 and A in 2010?`

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

CREATE TABLE "singles_performance_timeline" (
  "tournament" text,
  "2006" text,
  "2007" text,
  "2008" text,
  "2009" text,
  "2010" text,
  "2011" text,
  "2012" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2006 result of the Canada Masters tournament that is A in 2009 and A in 2010?`:
```sql
                SELECT "2006" FROM "singles_performance_timeline" WHERE "2010"='a' AND "2009"='a' AND "tournament"='canada masters';
```
## Task
Generate a SQL query to answer the following question:
`What is the result for 2006 of a tournament that is 107 in 2010?`

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

CREATE TABLE "singles_performance_timeline" (
  "tournament" text,
  "2006" text,
  "2007" text,
  "2008" text,
  "2009" text,
  "2010" text,
  "2011" text,
  "2012" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the result for 2006 of a tournament that is 107 in 2010?`:
```sql
                SELECT "2006" FROM "singles_performance_timeline" WHERE "2010"='107';
```
## Task
Generate a SQL query to answer the following question:
`What is the 2010 result of a tournament that is A in 2006 and A in 2011?`

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

CREATE TABLE "singles_performance_timeline" (
  "tournament" text,
  "2006" text,
  "2007" text,
  "2008" text,
  "2009" text,
  "2010" text,
  "2011" text,
  "2012" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2010 result of a tournament that is A in 2006 and A in 2011?`:
```sql
                SELECT "2010" FROM "singles_performance_timeline" WHERE "2011"='a' AND "2006"='a';
```
## Task
Generate a SQL query to answer the following question:
`What is the 2012 result of a tournament that is 2R in 2007, 1R in 2008 and 1R in 2009?`

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

CREATE TABLE "singles_performance_timeline" (
  "tournament" text,
  "2006" text,
  "2007" text,
  "2008" text,
  "2009" text,
  "2010" text,
  "2011" text,
  "2012" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2012 result of a tournament that is 2R in 2007, 1R in 2008 and 1R in 2009?`:
```sql
                SELECT "2012" FROM "singles_performance_timeline" WHERE "2009"='1r' AND "2008"='1r' AND "2007"='2r';
```
## Task
Generate a SQL query to answer the following question:
`What is the 2010 result of a tournament that is 1R in 2009, Q2 in 2011 and 1R in 2012?`

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

CREATE TABLE "singles_performance_timeline" (
  "tournament" text,
  "2006" text,
  "2007" text,
  "2008" text,
  "2009" text,
  "2010" text,
  "2011" text,
  "2012" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2010 result of a tournament that is 1R in 2009, Q2 in 2011 and 1R in 2012?`:
```sql
                SELECT "2010" FROM "singles_performance_timeline" WHERE "2011"='q2' AND "2012"='1r' AND "2009"='1r';
```
## Task
Generate a SQL query to answer the following question:
`What match number took place on August 3, 2007?`

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

CREATE TABLE "pre_season_tournaments_and_friendlies" (
  "match" real,
  "date" text,
  "tournament" text,
  "location" text,
  "opponent_team" text,
  "score" text
);
### SQL
Given the database schema, here is the SQL query that answers `What match number took place on August 3, 2007?`:
```sql
                SELECT MAX("match") FROM "pre_season_tournaments_and_friendlies" WHERE "date"='august 3, 2007';
```
## Task
Generate a SQL query to answer the following question:
`What is the 2010 value of the 2013 Grand Slam Tournaments?`

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

CREATE TABLE "mixed_doubles_performance_timeline" (
  "tournament" text,
  "2007" text,
  "2008" text,
  "2009" text,
  "2010" text,
  "2011" text,
  "2012" text,
  "2013" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2010 value of the 2013 Grand Slam Tournaments?`:
```sql
                SELECT "2010" FROM "mixed_doubles_performance_timeline" WHERE "2013"='grand slam tournaments';
```
## Task
Generate a SQL query to answer the following question:
`What is the 2012 value with A in 2007 and qf in 2011?`

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

CREATE TABLE "mixed_doubles_performance_timeline" (
  "tournament" text,
  "2007" text,
  "2008" text,
  "2009" text,
  "2010" text,
  "2011" text,
  "2012" text,
  "2013" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2012 value with A in 2007 and qf in 2011?`:
```sql
                SELECT "2012" FROM "mixed_doubles_performance_timeline" WHERE "2007"='a' AND "2011"='qf';
```
## Task
Generate a SQL query to answer the following question:
`What is the 2012 value with a 1r in 2011 in the Australian Open?`

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

CREATE TABLE "mixed_doubles_performance_timeline" (
  "tournament" text,
  "2007" text,
  "2008" text,
  "2009" text,
  "2010" text,
  "2011" text,
  "2012" text,
  "2013" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2012 value with a 1r in 2011 in the Australian Open?`:
```sql
                SELECT "2012" FROM "mixed_doubles_performance_timeline" WHERE "2011"='1r' AND "tournament"='australian open';
```
## Task
Generate a SQL query to answer the following question:
`What is the 2013 value with a qf in 2011?`

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

CREATE TABLE "mixed_doubles_performance_timeline" (
  "tournament" text,
  "2007" text,
  "2008" text,
  "2009" text,
  "2010" text,
  "2011" text,
  "2012" text,
  "2013" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2013 value with a qf in 2011?`:
```sql
                SELECT "2013" FROM "mixed_doubles_performance_timeline" WHERE "2011"='qf';
```
## Task
Generate a SQL query to answer the following question:
`What is the 2007 value at the 2012 Grand Slam Tournaments?`

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

CREATE TABLE "mixed_doubles_performance_timeline" (
  "tournament" text,
  "2007" text,
  "2008" text,
  "2009" text,
  "2010" text,
  "2011" text,
  "2012" text,
  "2013" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2007 value at the 2012 Grand Slam Tournaments?`:
```sql
                SELECT "2007" FROM "mixed_doubles_performance_timeline" WHERE "2012"='grand slam tournaments';
```
## Task
Generate a SQL query to answer the following question:
`Which tournament had a qf in 2011?`

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

CREATE TABLE "mixed_doubles_performance_timeline" (
  "tournament" text,
  "2007" text,
  "2008" text,
  "2009" text,
  "2010" text,
  "2011" text,
  "2012" text,
  "2013" text
);
### SQL
Given the database schema, here is the SQL query that answers `Which tournament had a qf in 2011?`:
```sql
                SELECT "tournament" FROM "mixed_doubles_performance_timeline" WHERE "2011"='qf';
```
## Task
Generate a SQL query to answer the following question:
`What is the 2009 first time percentage of the mg general science 5-9 exam with a 2008 first time percentage of 54%?`

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

CREATE TABLE "passing_rates" (
  "exam" text,
  "2006_first_time" text,
  "2006_all" text,
  "2007_first_time" text,
  "2007_all" text,
  "2008_first_time" text,
  "2008_all" text,
  "2009_first_time" text,
  "2009_all" text,
  "2010_first_time" text,
  "2011_first_time" text,
  "2012_first_time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2009 first time percentage of the mg general science 5-9 exam with a 2008 first time percentage of 54%?`:
```sql
                SELECT "2009_first_time" FROM "passing_rates" WHERE "2008_first_time"='54%' AND "exam"='mg general science 5-9';
```
## Task
Generate a SQL query to answer the following question:
`What is the 2008 all percentage of the exam with a 2007 first time percentage of 74%?`

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

CREATE TABLE "passing_rates" (
  "exam" text,
  "2006_first_time" text,
  "2006_all" text,
  "2007_first_time" text,
  "2007_all" text,
  "2008_first_time" text,
  "2008_all" text,
  "2009_first_time" text,
  "2009_all" text,
  "2010_first_time" text,
  "2011_first_time" text,
  "2012_first_time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2008 all percentage of the exam with a 2007 first time percentage of 74%?`:
```sql
                SELECT "2008_all" FROM "passing_rates" WHERE "2007_first_time"='74%';
```
## Task
Generate a SQL query to answer the following question:
`What is the 2009 first time percentage of the exam with a 2010 first time percentage of 88%?`

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

CREATE TABLE "passing_rates" (
  "exam" text,
  "2006_first_time" text,
  "2006_all" text,
  "2007_first_time" text,
  "2007_all" text,
  "2008_first_time" text,
  "2008_all" text,
  "2009_first_time" text,
  "2009_all" text,
  "2010_first_time" text,
  "2011_first_time" text,
  "2012_first_time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2009 first time percentage of the exam with a 2010 first time percentage of 88%?`:
```sql
                SELECT "2009_first_time" FROM "passing_rates" WHERE "2010_first_time"='88%';
```
## Task
Generate a SQL query to answer the following question:
`What is the 2009 all percentage of the exam with a 2007 first time percentage of 49%?`

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

CREATE TABLE "passing_rates" (
  "exam" text,
  "2006_first_time" text,
  "2006_all" text,
  "2007_first_time" text,
  "2007_all" text,
  "2008_first_time" text,
  "2008_all" text,
  "2009_first_time" text,
  "2009_all" text,
  "2010_first_time" text,
  "2011_first_time" text,
  "2012_first_time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2009 all percentage of the exam with a 2007 first time percentage of 49%?`:
```sql
                SELECT "2009_all" FROM "passing_rates" WHERE "2007_first_time"='49%';
```
## Task
Generate a SQL query to answer the following question:
`What is the 2006 first time percentage of the exam witha 2009 all percentage of 62%?`

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

CREATE TABLE "passing_rates" (
  "exam" text,
  "2006_first_time" text,
  "2006_all" text,
  "2007_first_time" text,
  "2007_all" text,
  "2008_first_time" text,
  "2008_all" text,
  "2009_first_time" text,
  "2009_all" text,
  "2010_first_time" text,
  "2011_first_time" text,
  "2012_first_time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2006 first time percentage of the exam witha 2009 all percentage of 62%?`:
```sql
                SELECT "2006_first_time" FROM "passing_rates" WHERE "2009_all"='62%';
```
## Task
Generate a SQL query to answer the following question:
`What is the 2006 first time percentage of the exam with a 2009 all percentage of 72% and a 2007 first time percentage of 85%?`

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

CREATE TABLE "passing_rates" (
  "exam" text,
  "2006_first_time" text,
  "2006_all" text,
  "2007_first_time" text,
  "2007_all" text,
  "2008_first_time" text,
  "2008_all" text,
  "2009_first_time" text,
  "2009_all" text,
  "2010_first_time" text,
  "2011_first_time" text,
  "2012_first_time" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the 2006 first time percentage of the exam with a 2009 all percentage of 72% and a 2007 first time percentage of 85%?`:
```sql
                SELECT "2006_first_time" FROM "passing_rates" WHERE "2009_all"='72%' AND "2007_first_time"='85%';
```
## Task
Generate a SQL query to answer the following question:
`What was the score for the 2014 FIFA World Cup Qual. competition?`

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

CREATE TABLE "international_goals" (
  "date" text,
  "venue" text,
  "score" text,
  "result" text,
  "competition" text
);
### SQL
Given the database schema, here is the SQL query that answers `What was the score for the 2014 FIFA World Cup Qual. competition?`:
```sql
                SELECT "score" FROM "international_goals" WHERE "competition"='2014 fifa world cup qual.';
```
## Task
Generate a SQL query to answer the following question:
`What is the highest number of matches with less than 2 draws that had an efficiency percent of 25%?`

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

CREATE TABLE "coaches" (
  "name" text,
  "period" text,
  "matches" real,
  "wins" real,
  "draws" real,
  "losses" real,
  "efficiency_pct" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the highest number of matches with less than 2 draws that had an efficiency percent of 25%?`:
```sql
                SELECT MAX("matches") FROM "coaches" WHERE "draws"<2 AND "efficiency_pct"='25%';
```
## Task
Generate a SQL query to answer the following question:
`What is the total number of Draws with less than 4 matches?`

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

CREATE TABLE "coaches" (
  "name" text,
  "period" text,
  "matches" real,
  "wins" real,
  "draws" real,
  "losses" real,
  "efficiency_pct" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the total number of Draws with less than 4 matches?`:
```sql
                SELECT COUNT("draws") FROM "coaches" WHERE "matches"<4;
```
## Task
Generate a SQL query to answer the following question:
`What is the average MHz Frequency of radio rezonans?`

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

CREATE TABLE "analogue_radio_programmes" (
  "program" text,
  "frequency_m_hz" real,
  "erp_k_w" real,
  "polarisation" text,
  "antenna_diagram_around_nd_directional_d" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average MHz Frequency of radio rezonans?`:
```sql
                SELECT AVG("frequency_m_hz") FROM "analogue_radio_programmes" WHERE "program"='radio rezonans';
```
## Task
Generate a SQL query to answer the following question:
`What date shows a Loss of lilly (2–2)?`

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

CREATE TABLE "game_log" (
  "date" text,
  "opponent" text,
  "score" text,
  "loss" text,
  "time" text,
  "att" text,
  "record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What date shows a Loss of lilly (2–2)?`:
```sql
                SELECT "date" FROM "game_log" WHERE "loss"='lilly (2–2)';
```
## Task
Generate a SQL query to answer the following question:
`What is the loss when the time was 3:16, and a Record of 15–15?`

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

CREATE TABLE "game_log" (
  "date" text,
  "opponent" text,
  "score" text,
  "loss" text,
  "time" text,
  "att" text,
  "record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the loss when the time was 3:16, and a Record of 15–15?`:
```sql
                SELECT "loss" FROM "game_log" WHERE "time"='3:16' AND "record"='15–15';
```
## Task
Generate a SQL query to answer the following question:
`What team was the opponent when the time was 2:57, and a Score of 7–5?`

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

CREATE TABLE "game_log" (
  "date" text,
  "opponent" text,
  "score" text,
  "loss" text,
  "time" text,
  "att" text,
  "record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What team was the opponent when the time was 2:57, and a Score of 7–5?`:
```sql
                SELECT "opponent" FROM "game_log" WHERE "time"='2:57' AND "score"='7–5';
```
## Task
Generate a SQL query to answer the following question:
`What date was the loss of ponson (4–3)?`

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

CREATE TABLE "game_log" (
  "date" text,
  "opponent" text,
  "score" text,
  "loss" text,
  "time" text,
  "att" text,
  "record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What date was the loss of ponson (4–3)?`:
```sql
                SELECT "date" FROM "game_log" WHERE "loss"='ponson (4–3)';
```
## Task
Generate a SQL query to answer the following question:
`What date was the loss of sparks (0–1)?`

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

CREATE TABLE "game_log" (
  "date" text,
  "opponent" text,
  "score" text,
  "loss" text,
  "time" text,
  "att" text,
  "record" text
);
### SQL
Given the database schema, here is the SQL query that answers `What date was the loss of sparks (0–1)?`:
```sql
                SELECT "date" FROM "game_log" WHERE "loss"='sparks (0–1)';
```
## Task
Generate a SQL query to answer the following question:
`What is the position of the competition in Tampere, Finland?`

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

CREATE TABLE "achievements" (
  "year" real,
  "competition" text,
  "venue" text,
  "position" text,
  "event" text
);
### SQL
Given the database schema, here is the SQL query that answers `What is the position of the competition in Tampere, Finland?`:
```sql
                SELECT "position" FROM "achievements" WHERE "venue"='tampere, finland';
```
## Task
Generate a SQL query to answer the following question:
`What is the lowest total that has draws less than 2 and wins less than 1, losses bigger than 1 with a goal difference of 1:2`

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

CREATE TABLE "montenegro_versus_other_countries" (
  "wins" real,
  "draws" real,
  "losses" real,
  "goal_difference" text,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest total that has draws less than 2 and wins less than 1, losses bigger than 1 with a goal difference of 1:2`:
```sql
                SELECT MIN("total") FROM "montenegro_versus_other_countries" WHERE "draws"<2 AND "wins"<1 AND "goal_difference"='1:2' AND "losses">1;
```
## Task
Generate a SQL query to answer the following question:
`What is the average number of draws that have a total of 1 and a goal difference of 2:0?`

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

CREATE TABLE "montenegro_versus_other_countries" (
  "wins" real,
  "draws" real,
  "losses" real,
  "goal_difference" text,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the average number of draws that have a total of 1 and a goal difference of 2:0?`:
```sql
                SELECT AVG("draws") FROM "montenegro_versus_other_countries" WHERE "total"=1 AND "goal_difference"='2:0';
```
## Task
Generate a SQL query to answer the following question:
`What is the lowest number of draws that have a goal difference of 0:2 and wins greater than 0?`

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

CREATE TABLE "montenegro_versus_other_countries" (
  "wins" real,
  "draws" real,
  "losses" real,
  "goal_difference" text,
  "total" real
);
### SQL
Given the database schema, here is the SQL query that answers `What is the lowest number of draws that have a goal difference of 0:2 and wins greater than 0?`:
```sql
                SELECT MIN("draws") FROM "montenegro_versus_other_countries" WHERE "goal_difference"='0:2' AND "wins">0;
```
## Task
Generate a SQL query to answer the following question:
`What regular season had an average attendance of 1,242?`

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

CREATE TABLE "year_by_year" (
  "year" text,
  "league" text,
  "reg_season" text,
  "playoffs" text,
  "avg_attendance" text
);
### SQL
Given the database schema, here is the SQL query that answers `What regular season had an average attendance of 1,242?`:
```sql
                SELECT "reg_season" FROM "year_by_year" WHERE "avg_attendance"='1,242';
```
## Task
Generate a SQL query to answer the following question:
`What league has an average attendance of 244?`

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

CREATE TABLE "year_by_year" (
  "year" text,
  "league" text,
  "reg_season" text,
  "playoffs" text,
  "avg_attendance" text
);
### SQL
Given the database schema, here is the SQL query that answers `What league has an average attendance of 244?`:
```sql
                SELECT "league" FROM "year_by_year" WHERE "avg_attendance"='244';
```