MMTU-benchmark/MMTU huggingface dataset:
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
movie_2

Tables:

Table: Movies
|   Code | Title                   | Rating   |
|-------:|:------------------------|:---------|
|      1 | Citizen Kane            | PG       |
|      2 | Singin' in the Rain     | G        |
|      3 | The Wizard of Oz        | G        |
|      4 | The Quiet Man           |          |
|      5 | North by Northwest      |          |
|      6 | The Last Tango in Paris | NC-17    |
|      7 | Some Like it Hot        | PG-13    |
|      8 | A Night at the Opera    |          |


Table: MovieTheaters
|   Code | Name        | Movie   |
|-------:|:------------|:--------|
|      1 | Odeon       | 5.0     |
|      2 | Imperial    | 1.0     |
|      3 | Majestic    |         |
|      4 | Royale      | 6.0     |
|      5 | Paraiso     | 3.0     |
|      6 | Nickelodeon |         |


Question: What is the name of the film playing at the most number of theaters?

db_id: movie_2
tables: name: Movies
data: Movies.csv
name: MovieTheaters
data: MovieTheaters.csv
label: SELECT T1.title FROM movies AS T1 JOIN movietheaters AS T2 ON T1.code  =  T2.movie GROUP BY T1.title ORDER BY count(*) DESC LIMIT 1
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/movie_2/movie_2.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
warehouse_1

Tables:

Table: Warehouses
|   Code | Location      |   Capacity |
|-------:|:--------------|-----------:|
|      1 | Chicago       |          3 |
|      2 | Chicago       |          4 |
|      3 | New York      |          7 |
|      4 | Los Angeles   |          2 |
|      5 | San Francisco |          8 |


Table: Boxes
| Code   | Contents   |   Value |   Warehouse |
|:-------|:-----------|--------:|------------:|
| 0MN7   | Rocks      |     180 |           3 |
| 4H8P   | Rocks      |     250 |           1 |
| 4RT3   | Scissors   |     190 |           4 |
| 7G3H   | Rocks      |     200 |           1 |
| 8JN6   | Papers     |      75 |           1 |
| 8Y6U   | Papers     |      50 |           3 |
| 9J6F   | Papers     |     175 |           2 |
| LL08   | Rocks      |     140 |           4 |
| P0H6   | Scissors   |     125 |           1 |
| P2T6   | Scissors   |     150 |           2 |


Question: What are the codes of boxes stored in warehouses in Chicago?

db_id: warehouse_1
tables: name: Warehouses
data: Warehouses.csv
name: Boxes
data: Boxes.csv
label: SELECT T1.code FROM boxes AS T1 JOIN Warehouses AS T2 ON T1.warehouse  =  T2.code WHERE T2.location  =  'Chicago'
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/warehouse_1/warehouse_1.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
boat_1

Tables:

Table: Sailors
|   sid | name   |   rating |   age |
|------:|:-------|---------:|------:|
|     1 | Eugene |        7 |    22 |
|     2 | Luis   |        2 |    39 |
|     3 | Ken    |        8 |    27 |


Table: Boats
|   bid | name   | color   |
|------:|:-------|:--------|
|   101 | Legacy | red     |
|   102 | Melon  | blue    |
|   103 | Mars   | red     |


Table: Reserves
|   sid |   bid | day   |
|------:|------:|:------|
|     1 |   102 | 9/12  |
|     2 |   102 | 9/13  |
|     2 |   103 | 9/14  |
|     2 |   103 | 9/15  |


Question: Return the unique boat ids (bid) of all reserved boats.

db_id: boat_1
tables: name: Sailors
data: Sailors.csv
name: Boats
data: Boats.csv
name: Reserves
data: Reserves.csv
label: SELECT DISTINCT bid FROM Reserves
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/boat_1/boat_1.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
pilot_1

Tables:

Table: PilotSkills
| pilot_name   | plane_name   |   age |
|:-------------|:-------------|------:|
| Celko        | Piper Cub    |    23 |
| Higgins      | B-52 Bomber  |    34 |
| Higgins      | F-14 Fighter |    50 |
| Higgins      | Piper Cub    |    30 |
| Jones        | B-52 Bomber  |    24 |
| Jones        | F-14 Fighter |    32 |
| Smith        | B-1 Bomber   |    41 |
| Smith        | B-52 Bomber  |    26 |
| Smith        | F-14 Fighter |    45 |
| Wilson       | B-1 Bomber   |    52 |


Table: Hangar
| plane_name   | location   |
|:-------------|:-----------|
| B-1 Bomber   | Chicago    |
| B-52 Bomber  | Austin     |
| F-14 Fighter | Boston     |
| Piper Cub    | Seattle    |


Question: What is all the information about pilots who are younger than 30 ?

db_id: pilot_1
tables: name: PilotSkills
data: PilotSkills.csv
name: Hangar
data: Hangar.csv
label: select * from pilotskills where age  <  30
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/pilot_1/pilot_1.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
boat_1

Tables:

Table: Sailors
|   sid | name   |   rating |   age |
|------:|:-------|---------:|------:|
|     1 | Eugene |        7 |    22 |
|     2 | Luis   |        2 |    39 |
|     3 | Ken    |        8 |    27 |


Table: Boats
|   bid | name   | color   |
|------:|:-------|:--------|
|   101 | Legacy | red     |
|   102 | Melon  | blue    |
|   103 | Mars   | red     |


Table: Reserves
|   sid |   bid | day   |
|------:|------:|:------|
|     1 |   102 | 9/12  |
|     2 |   102 | 9/13  |
|     2 |   103 | 9/14  |
|     2 |   103 | 9/15  |


Question: Return all details of sailors who are older than 30.

db_id: boat_1
tables: name: Sailors
data: Sailors.csv
name: Boats
data: Boats.csv
name: Reserves
data: Reserves.csv
label: SELECT * FROM Sailors WHERE age  >  30
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/boat_1/boat_1.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
movie_2

Tables:

Table: Movies
|   Code | Title                   | Rating   |
|-------:|:------------------------|:---------|
|      1 | Citizen Kane            | PG       |
|      2 | Singin' in the Rain     | G        |
|      3 | The Wizard of Oz        | G        |
|      4 | The Quiet Man           |          |
|      5 | North by Northwest      |          |
|      6 | The Last Tango in Paris | NC-17    |
|      7 | Some Like it Hot        | PG-13    |
|      8 | A Night at the Opera    |          |


Table: MovieTheaters
|   Code | Name        | Movie   |
|-------:|:------------|:--------|
|      1 | Odeon       | 5.0     |
|      2 | Imperial    | 1.0     |
|      3 | Majestic    |         |
|      4 | Royale      | 6.0     |
|      5 | Paraiso     | 3.0     |
|      6 | Nickelodeon |         |


Question: Find the name of the movie that is on in both Odeon and Imperial theaters.

db_id: movie_2
tables: name: Movies
data: Movies.csv
name: MovieTheaters
data: MovieTheaters.csv
label: SELECT T1.title FROM movies AS T1 JOIN movietheaters AS T2 ON T1.code  =  T2.movie WHERE T2.name  =  'Odeon' INTERSECT SELECT T1.title FROM movies AS T1 JOIN movietheaters AS T2 ON T1.code  =  T2.movie WHERE T2.name  =  'Imperial'
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/movie_2/movie_2.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
movie_2

Tables:

Table: Movies
|   Code | Title                   | Rating   |
|-------:|:------------------------|:---------|
|      1 | Citizen Kane            | PG       |
|      2 | Singin' in the Rain     | G        |
|      3 | The Wizard of Oz        | G        |
|      4 | The Quiet Man           |          |
|      5 | North by Northwest      |          |
|      6 | The Last Tango in Paris | NC-17    |
|      7 | Some Like it Hot        | PG-13    |
|      8 | A Night at the Opera    |          |


Table: MovieTheaters
|   Code | Name        | Movie   |
|-------:|:------------|:--------|
|      1 | Odeon       | 5.0     |
|      2 | Imperial    | 1.0     |
|      3 | Majestic    |         |
|      4 | Royale      | 6.0     |
|      5 | Paraiso     | 3.0     |
|      6 | Nickelodeon |         |


Question: How many different movies are playing?

db_id: movie_2
tables: name: Movies
data: Movies.csv
name: MovieTheaters
data: MovieTheaters.csv
label: SELECT count(DISTINCT T1.code) FROM movies AS T1 JOIN movietheaters AS T2 ON T1.code  =  T2.movie
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/movie_2/movie_2.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
pilot_1

Tables:

Table: PilotSkills
| pilot_name   | plane_name   |   age |
|:-------------|:-------------|------:|
| Celko        | Piper Cub    |    23 |
| Higgins      | B-52 Bomber  |    34 |
| Higgins      | F-14 Fighter |    50 |
| Higgins      | Piper Cub    |    30 |
| Jones        | B-52 Bomber  |    24 |
| Jones        | F-14 Fighter |    32 |
| Smith        | B-1 Bomber   |    41 |
| Smith        | B-52 Bomber  |    26 |
| Smith        | F-14 Fighter |    45 |
| Wilson       | B-1 Bomber   |    52 |


Table: Hangar
| plane_name   | location   |
|:-------------|:-----------|
| B-1 Bomber   | Chicago    |
| B-52 Bomber  | Austin     |
| F-14 Fighter | Boston     |
| Piper Cub    | Seattle    |


Question: Count the number of planes Smith owns.

db_id: pilot_1
tables: name: PilotSkills
data: PilotSkills.csv
name: Hangar
data: Hangar.csv
label: SELECT count(plane_name) FROM pilotskills WHERE pilot_name  =  'Smith'
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/pilot_1/pilot_1.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
movie_2

Tables:

Table: Movies
|   Code | Title                   | Rating   |
|-------:|:------------------------|:---------|
|      1 | Citizen Kane            | PG       |
|      2 | Singin' in the Rain     | G        |
|      3 | The Wizard of Oz        | G        |
|      4 | The Quiet Man           |          |
|      5 | North by Northwest      |          |
|      6 | The Last Tango in Paris | NC-17    |
|      7 | Some Like it Hot        | PG-13    |
|      8 | A Night at the Opera    |          |


Table: MovieTheaters
|   Code | Name        | Movie   |
|-------:|:------------|:--------|
|      1 | Odeon       | 5.0     |
|      2 | Imperial    | 1.0     |
|      3 | Majestic    |         |
|      4 | Royale      | 6.0     |
|      5 | Paraiso     | 3.0     |
|      6 | Nickelodeon |         |


Question: List in alphabetical order the titles of all movies.

db_id: movie_2
tables: name: Movies
data: Movies.csv
name: MovieTheaters
data: MovieTheaters.csv
label: SELECT title FROM movies ORDER BY title
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/movie_2/movie_2.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
warehouse_1

Tables:

Table: Warehouses
|   Code | Location      |   Capacity |
|-------:|:--------------|-----------:|
|      1 | Chicago       |          3 |
|      2 | Chicago       |          4 |
|      3 | New York      |          7 |
|      4 | Los Angeles   |          2 |
|      5 | San Francisco |          8 |


Table: Boxes
| Code   | Contents   |   Value |   Warehouse |
|:-------|:-----------|--------:|------------:|
| 0MN7   | Rocks      |     180 |           3 |
| 4H8P   | Rocks      |     250 |           1 |
| 4RT3   | Scissors   |     190 |           4 |
| 7G3H   | Rocks      |     200 |           1 |
| 8JN6   | Papers     |      75 |           1 |
| 8Y6U   | Papers     |      50 |           3 |
| 9J6F   | Papers     |     175 |           2 |
| LL08   | Rocks      |     140 |           4 |
| P0H6   | Scissors   |     125 |           1 |
| P2T6   | Scissors   |     150 |           2 |


Question: Select the warehouse code and the average value of the boxes in each warehouse.

db_id: warehouse_1
tables: name: Warehouses
data: Warehouses.csv
name: Boxes
data: Boxes.csv
label: SELECT warehouse ,  avg(value) FROM boxes GROUP BY warehouse
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/warehouse_1/warehouse_1.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
boat_1

Tables:

Table: Sailors
|   sid | name   |   rating |   age |
|------:|:-------|---------:|------:|
|     1 | Eugene |        7 |    22 |
|     2 | Luis   |        2 |    39 |
|     3 | Ken    |        8 |    27 |


Table: Boats
|   bid | name   | color   |
|------:|:-------|:--------|
|   101 | Legacy | red     |
|   102 | Melon  | blue    |
|   103 | Mars   | red     |


Table: Reserves
|   sid |   bid | day   |
|------:|------:|:------|
|     1 |   102 | 9/12  |
|     2 |   102 | 9/13  |
|     2 |   103 | 9/14  |
|     2 |   103 | 9/15  |


Question: Find the id of Sailors (sid) that reserved red or blue boat.

db_id: boat_1
tables: name: Sailors
data: Sailors.csv
name: Boats
data: Boats.csv
name: Reserves
data: Reserves.csv
label: SELECT DISTINCT T2.sid FROM Boats AS T1 JOIN Reserves AS T2 ON  T1.bid  =  T2.bid WHERE T1.color  =  'red' OR T1.color  =  "blue"
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/boat_1/boat_1.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
book_review

Tables:

Table: book
|   Book_ID | Title                | Type   |   Pages |   Chapters | Audio   | Release       |
|----------:|:---------------------|:-------|--------:|-----------:|:--------|:--------------|
|         1 | A Game of Thrones    | Novel  |     704 |         73 | 33h 53m | August 1996   |
|         2 | A Clash of Kings     | Novel  |     768 |         70 | 37h 17m | February 1999 |
|         3 | A Storm of Swords    | Novel  |     992 |         82 | 47h 37m | November 2000 |
|         4 | A Feast for Crows    | Novel  |     753 |         46 | 31h 10m | November 2005 |
|         5 | A Dance with Dragons | Poet   |    1056 |         73 | 48h 56m | July 2011     |


Table: review
|   Review_ID |   Book_ID |   Rating |   Readers_in_Million |   Rank |
|------------:|----------:|---------:|---------------------:|-------:|
|           1 |         1 |      6.6 |                  3.3 |     16 |
|           2 |         3 |      5.7 |                  2.8 |     25 |
|           3 |         4 |      5.8 |                  2.6 |     26 |
|           4 |         5 |      5.6 |                  2.4 |     35 |


Question: What is the rank of the book with the smallest number of pages?

db_id: book_review
tables: name: book
data: book.csv
name: review
data: review.csv
label: SELECT T2.Rank FROM book AS T1 JOIN review AS T2 ON T1.Book_ID  =  T2.Book_ID ORDER BY T1.Pages ASC LIMIT 1
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/book_review/book_review.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
book_review

Tables:

Table: book
|   Book_ID | Title                | Type   |   Pages |   Chapters | Audio   | Release       |
|----------:|:---------------------|:-------|--------:|-----------:|:--------|:--------------|
|         1 | A Game of Thrones    | Novel  |     704 |         73 | 33h 53m | August 1996   |
|         2 | A Clash of Kings     | Novel  |     768 |         70 | 37h 17m | February 1999 |
|         3 | A Storm of Swords    | Novel  |     992 |         82 | 47h 37m | November 2000 |
|         4 | A Feast for Crows    | Novel  |     753 |         46 | 31h 10m | November 2005 |
|         5 | A Dance with Dragons | Poet   |    1056 |         73 | 48h 56m | July 2011     |


Table: review
|   Review_ID |   Book_ID |   Rating |   Readers_in_Million |   Rank |
|------------:|----------:|---------:|---------------------:|-------:|
|           1 |         1 |      6.6 |                  3.3 |     16 |
|           2 |         3 |      5.7 |                  2.8 |     25 |
|           3 |         4 |      5.8 |                  2.6 |     26 |
|           4 |         5 |      5.6 |                  2.4 |     35 |


Question: What are the type and title of the books that are not rated?

db_id: book_review
tables: name: book
data: book.csv
name: review
data: review.csv
label: SELECT TYPE ,  title FROM book EXCEPT SELECT T1.type ,  T1.title FROM book AS T1 JOIN review AS T2 ON T1.Book_ID  =  T2.Book_ID;
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/book_review/book_review.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
book_review

Tables:

Table: book
|   Book_ID | Title                | Type   |   Pages |   Chapters | Audio   | Release       |
|----------:|:---------------------|:-------|--------:|-----------:|:--------|:--------------|
|         1 | A Game of Thrones    | Novel  |     704 |         73 | 33h 53m | August 1996   |
|         2 | A Clash of Kings     | Novel  |     768 |         70 | 37h 17m | February 1999 |
|         3 | A Storm of Swords    | Novel  |     992 |         82 | 47h 37m | November 2000 |
|         4 | A Feast for Crows    | Novel  |     753 |         46 | 31h 10m | November 2005 |
|         5 | A Dance with Dragons | Poet   |    1056 |         73 | 48h 56m | July 2011     |


Table: review
|   Review_ID |   Book_ID |   Rating |   Readers_in_Million |   Rank |
|------------:|----------:|---------:|---------------------:|-------:|
|           1 |         1 |      6.6 |                  3.3 |     16 |
|           2 |         3 |      5.7 |                  2.8 |     25 |
|           3 |         4 |      5.8 |                  2.6 |     26 |
|           4 |         5 |      5.6 |                  2.4 |     35 |


Question: For each book type return the type and the number of books of that type.

db_id: book_review
tables: name: book
data: book.csv
name: review
data: review.csv
label: SELECT TYPE ,  COUNT(*) FROM book GROUP BY TYPE
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/book_review/book_review.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
boat_1

Tables:

Table: Sailors
|   sid | name   |   rating |   age |
|------:|:-------|---------:|------:|
|     1 | Eugene |        7 |    22 |
|     2 | Luis   |        2 |    39 |
|     3 | Ken    |        8 |    27 |


Table: Boats
|   bid | name   | color   |
|------:|:-------|:--------|
|   101 | Legacy | red     |
|   102 | Melon  | blue    |
|   103 | Mars   | red     |


Table: Reserves
|   sid |   bid | day   |
|------:|------:|:------|
|     1 |   102 | 9/12  |
|     2 |   102 | 9/13  |
|     2 |   103 | 9/14  |
|     2 |   103 | 9/15  |


Question: Find the names of boats booked by sailors whose age is between 20 and 30.

db_id: boat_1
tables: name: Sailors
data: Sailors.csv
name: Boats
data: Boats.csv
name: Reserves
data: Reserves.csv
label: SELECT T3.name FROM Sailors AS T1 JOIN Reserves AS T2 ON T1.sid  =  T2.sid JOIN Boats AS T3 ON T3.bid  =  T2.bid WHERE T1.age BETWEEN 20 AND 30
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/boat_1/boat_1.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
boat_1

Tables:

Table: Sailors
|   sid | name   |   rating |   age |
|------:|:-------|---------:|------:|
|     1 | Eugene |        7 |    22 |
|     2 | Luis   |        2 |    39 |
|     3 | Ken    |        8 |    27 |


Table: Boats
|   bid | name   | color   |
|------:|:-------|:--------|
|   101 | Legacy | red     |
|   102 | Melon  | blue    |
|   103 | Mars   | red     |


Table: Reserves
|   sid |   bid | day   |
|------:|------:|:------|
|     1 |   102 | 9/12  |
|     2 |   102 | 9/13  |
|     2 |   103 | 9/14  |
|     2 |   103 | 9/15  |


Question: How many sailors exist?

db_id: boat_1
tables: name: Sailors
data: Sailors.csv
name: Boats
data: Boats.csv
name: Reserves
data: Reserves.csv
label: SELECT COUNT(*) FROM Sailors
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/boat_1/boat_1.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
warehouse_1

Tables:

Table: Warehouses
|   Code | Location      |   Capacity |
|-------:|:--------------|-----------:|
|      1 | Chicago       |          3 |
|      2 | Chicago       |          4 |
|      3 | New York      |          7 |
|      4 | Los Angeles   |          2 |
|      5 | San Francisco |          8 |


Table: Boxes
| Code   | Contents   |   Value |   Warehouse |
|:-------|:-----------|--------:|------------:|
| 0MN7   | Rocks      |     180 |           3 |
| 4H8P   | Rocks      |     250 |           1 |
| 4RT3   | Scissors   |     190 |           4 |
| 7G3H   | Rocks      |     200 |           1 |
| 8JN6   | Papers     |      75 |           1 |
| 8Y6U   | Papers     |      50 |           3 |
| 9J6F   | Papers     |     175 |           2 |
| LL08   | Rocks      |     140 |           4 |
| P0H6   | Scissors   |     125 |           1 |
| P2T6   | Scissors   |     150 |           2 |


Question: How many boxes are stored in each warehouse?

db_id: warehouse_1
tables: name: Warehouses
data: Warehouses.csv
name: Boxes
data: Boxes.csv
label: SELECT count(*) ,  warehouse FROM boxes GROUP BY warehouse
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/warehouse_1/warehouse_1.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
pilot_1

Tables:

Table: PilotSkills
| pilot_name   | plane_name   |   age |
|:-------------|:-------------|------:|
| Celko        | Piper Cub    |    23 |
| Higgins      | B-52 Bomber  |    34 |
| Higgins      | F-14 Fighter |    50 |
| Higgins      | Piper Cub    |    30 |
| Jones        | B-52 Bomber  |    24 |
| Jones        | F-14 Fighter |    32 |
| Smith        | B-1 Bomber   |    41 |
| Smith        | B-52 Bomber  |    26 |
| Smith        | F-14 Fighter |    45 |
| Wilson       | B-1 Bomber   |    52 |


Table: Hangar
| plane_name   | location   |
|:-------------|:-----------|
| B-1 Bomber   | Chicago    |
| B-52 Bomber  | Austin     |
| F-14 Fighter | Boston     |
| Piper Cub    | Seattle    |


Question: What are the names of pilots between the ages of 30 and 40, ordered by age ascending?

db_id: pilot_1
tables: name: PilotSkills
data: PilotSkills.csv
name: Hangar
data: Hangar.csv
label: SELECT pilot_name FROM pilotskills WHERE age BETWEEN 30 AND 40 ORDER BY age
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/pilot_1/pilot_1.sqlite
Task: NL2SQL (source dataset: Spider)

Natural language to SQL, also known as NL2SQL, is the problem of generating a SQL query that can be executed on a input table, for a given natural language question.

You will be given an input table called "table" in the markdown format, as well as a question. Your task is to generate an SQL query that can be executed on the input table to answer the question.

Please ensure that the generated SQL only return relevant columns being specifically asked in the question (e.g., in SQL please don't return more than one columns in SELECT if only one column is needed to answer the given question, and similarly please refrain from using SELECT * unless the entire row is needed to answer the question).
 
When generating SQL code, please use the SQLite syntax to ensure that your SQL is executable on SQLite3. Use only columns that are present in the table, always use quotes around your column and table names (some column names have punctuation or special characters), and refer to the columns using the column-names exactly as they appear in the table, do not add or remove punctuation (underscore, slash, etc.)

No explanation, return the code only with the following markdown codeblock format : ```sql<SQL CODE>```. For example, ```sql
SELECT * FROM "table"
``` is a valid format.

Database:
movie_2

Tables:

Table: Movies
|   Code | Title                   | Rating   |
|-------:|:------------------------|:---------|
|      1 | Citizen Kane            | PG       |
|      2 | Singin' in the Rain     | G        |
|      3 | The Wizard of Oz        | G        |
|      4 | The Quiet Man           |          |
|      5 | North by Northwest      |          |
|      6 | The Last Tango in Paris | NC-17    |
|      7 | Some Like it Hot        | PG-13    |
|      8 | A Night at the Opera    |          |


Table: MovieTheaters
|   Code | Name        | Movie   |
|-------:|:------------|:--------|
|      1 | Odeon       | 5.0     |
|      2 | Imperial    | 1.0     |
|      3 | Majestic    |         |
|      4 | Royale      | 6.0     |
|      5 | Paraiso     | 3.0     |
|      6 | Nickelodeon |         |


Question: Find the titles of all movies sorted by their ratings.

db_id: movie_2
tables: name: Movies
data: Movies.csv
name: MovieTheaters
data: MovieTheaters.csv
label: SELECT title FROM movies ORDER BY rating
sqlite_path: $MMTU_HOME/data_sqlite/spider/spider_data/test_database/movie_2/movie_2.sqlite