multispider / dataset /spider /database /chinook_1 /examples_en.json
dreamerdeo's picture
Upload folder using huggingface_hub
1faca1c
[
{
"db_id": "chinook_1",
"query": "SELECT count(*) FROM ALBUM",
"query_toks": [
"SELECT",
"count",
"(",
"*",
")",
"FROM",
"ALBUM"
],
"query_toks_no_value": [
"select",
"count",
"(",
"*",
")",
"from",
"album"
],
"question": "How many albums are there?",
"question_toks": [
"How",
"many",
"albums",
"are",
"there",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
0
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
3,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT count(*) FROM ALBUM",
"query_toks": [
"SELECT",
"count",
"(",
"*",
")",
"FROM",
"ALBUM"
],
"query_toks_no_value": [
"select",
"count",
"(",
"*",
")",
"from",
"album"
],
"question": "Find the number of albums.",
"question_toks": [
"Find",
"the",
"number",
"of",
"albums",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
0
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
3,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT Name FROM GENRE",
"query_toks": [
"SELECT",
"Name",
"FROM",
"GENRE"
],
"query_toks_no_value": [
"select",
"name",
"from",
"genre"
],
"question": "List the names of all music genres.",
"question_toks": [
"List",
"the",
"names",
"of",
"all",
"music",
"genres",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
4
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
35,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT Name FROM GENRE",
"query_toks": [
"SELECT",
"Name",
"FROM",
"GENRE"
],
"query_toks_no_value": [
"select",
"name",
"from",
"genre"
],
"question": "What are the names of different music genres?",
"question_toks": [
"What",
"are",
"the",
"names",
"of",
"different",
"music",
"genres",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
4
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
35,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT * FROM CUSTOMER WHERE State = \"NY\"",
"query_toks": [
"SELECT",
"*",
"FROM",
"CUSTOMER",
"WHERE",
"State",
"=",
"``",
"NY",
"''"
],
"query_toks_no_value": [
"select",
"*",
"from",
"customer",
"where",
"state",
"=",
"value"
],
"question": "Find all the customer information in state NY.",
"question_toks": [
"Find",
"all",
"the",
"customer",
"information",
"in",
"state",
"NY",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
2
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
12,
false
],
null
],
"\"NY\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT * FROM CUSTOMER WHERE State = \"NY\"",
"query_toks": [
"SELECT",
"*",
"FROM",
"CUSTOMER",
"WHERE",
"State",
"=",
"``",
"NY",
"''"
],
"query_toks_no_value": [
"select",
"*",
"from",
"customer",
"where",
"state",
"=",
"value"
],
"question": "What is all the customer information for customers in NY state?",
"question_toks": [
"What",
"is",
"all",
"the",
"customer",
"information",
"for",
"customers",
"in",
"NY",
"state",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
2
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
12,
false
],
null
],
"\"NY\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT FirstName , LastName FROM EMPLOYEE WHERE City = \"Calgary\"",
"query_toks": [
"SELECT",
"FirstName",
",",
"LastName",
"FROM",
"EMPLOYEE",
"WHERE",
"City",
"=",
"``",
"Calgary",
"''"
],
"query_toks_no_value": [
"select",
"firstname",
",",
"lastname",
"from",
"employee",
"where",
"city",
"=",
"value"
],
"question": "What are the first names and last names of the employees who live in Calgary city.",
"question_toks": [
"What",
"are",
"the",
"first",
"names",
"and",
"last",
"names",
"of",
"the",
"employees",
"who",
"live",
"in",
"Calgary",
"city",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
3
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
21,
false
],
null
]
],
[
0,
[
0,
[
0,
20,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
27,
false
],
null
],
"\"Calgary\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT FirstName , LastName FROM EMPLOYEE WHERE City = \"Calgary\"",
"query_toks": [
"SELECT",
"FirstName",
",",
"LastName",
"FROM",
"EMPLOYEE",
"WHERE",
"City",
"=",
"``",
"Calgary",
"''"
],
"query_toks_no_value": [
"select",
"firstname",
",",
"lastname",
"from",
"employee",
"where",
"city",
"=",
"value"
],
"question": "Find the full names of employees living in the city of Calgary.",
"question_toks": [
"Find",
"the",
"full",
"names",
"of",
"employees",
"living",
"in",
"the",
"city",
"of",
"Calgary",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
3
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
21,
false
],
null
]
],
[
0,
[
0,
[
0,
20,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
27,
false
],
null
],
"\"Calgary\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT distinct(BillingCountry) FROM INVOICE",
"query_toks": [
"SELECT",
"distinct",
"(",
"BillingCountry",
")",
"FROM",
"INVOICE"
],
"query_toks_no_value": [
"select",
"distinct",
"(",
"billingcountry",
")",
"from",
"invoice"
],
"question": "What are the distinct billing countries of the invoices?",
"question_toks": [
"What",
"are",
"the",
"distinct",
"billing",
"countries",
"of",
"the",
"invoices",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
5
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
true,
[
[
0,
[
0,
[
0,
42,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT distinct(BillingCountry) FROM INVOICE",
"query_toks": [
"SELECT",
"distinct",
"(",
"BillingCountry",
")",
"FROM",
"INVOICE"
],
"query_toks_no_value": [
"select",
"distinct",
"(",
"billingcountry",
")",
"from",
"invoice"
],
"question": "Find the different billing countries for all invoices.",
"question_toks": [
"Find",
"the",
"different",
"billing",
"countries",
"for",
"all",
"invoices",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
5
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
true,
[
[
0,
[
0,
[
0,
42,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT Name FROM ARTIST WHERE Name LIKE \"%a%\"",
"query_toks": [
"SELECT",
"Name",
"FROM",
"ARTIST",
"WHERE",
"Name",
"LIKE",
"``",
"%",
"a",
"%",
"''"
],
"query_toks_no_value": [
"select",
"name",
"from",
"artist",
"where",
"name",
"like",
"value"
],
"question": "Find the names of all artists that have \"a\" in their names.",
"question_toks": [
"Find",
"the",
"names",
"of",
"all",
"artists",
"that",
"have",
"``",
"a",
"''",
"in",
"their",
"names",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
1
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
5,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
9,
[
0,
[
0,
5,
false
],
null
],
"\"%a%\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT Name FROM ARTIST WHERE Name LIKE \"%a%\"",
"query_toks": [
"SELECT",
"Name",
"FROM",
"ARTIST",
"WHERE",
"Name",
"LIKE",
"``",
"%",
"a",
"%",
"''"
],
"query_toks_no_value": [
"select",
"name",
"from",
"artist",
"where",
"name",
"like",
"value"
],
"question": "What are the names of artist who have the letter 'a' in their names?",
"question_toks": [
"What",
"are",
"the",
"names",
"of",
"artist",
"who",
"have",
"the",
"letter",
"'a",
"'",
"in",
"their",
"names",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
1
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
5,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
9,
[
0,
[
0,
5,
false
],
null
],
"\"%a%\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT Title FROM ALBUM AS T1 JOIN ARTIST AS T2 ON T1.ArtistId = T2.ArtistId WHERE T2.Name = \"AC/DC\"",
"query_toks": [
"SELECT",
"Title",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"ARTIST",
"AS",
"T2",
"ON",
"T1.ArtistId",
"=",
"T2.ArtistId",
"WHERE",
"T2.Name",
"=",
"``",
"AC/DC",
"''"
],
"query_toks_no_value": [
"select",
"title",
"from",
"album",
"as",
"t1",
"join",
"artist",
"as",
"t2",
"on",
"t1",
".",
"artistid",
"=",
"t2",
".",
"artistid",
"where",
"t2",
".",
"name",
"=",
"value"
],
"question": "Find the title of all the albums of the artist \"AC/DC\".",
"question_toks": [
"Find",
"the",
"title",
"of",
"all",
"the",
"albums",
"of",
"the",
"artist",
"``",
"AC/DC",
"''",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
3,
false
],
null
],
[
0,
4,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
1
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
2,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
5,
false
],
null
],
"\"AC/DC\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT Title FROM ALBUM AS T1 JOIN ARTIST AS T2 ON T1.ArtistId = T2.ArtistId WHERE T2.Name = \"AC/DC\"",
"query_toks": [
"SELECT",
"Title",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"ARTIST",
"AS",
"T2",
"ON",
"T1.ArtistId",
"=",
"T2.ArtistId",
"WHERE",
"T2.Name",
"=",
"``",
"AC/DC",
"''"
],
"query_toks_no_value": [
"select",
"title",
"from",
"album",
"as",
"t1",
"join",
"artist",
"as",
"t2",
"on",
"t1",
".",
"artistid",
"=",
"t2",
".",
"artistid",
"where",
"t2",
".",
"name",
"=",
"value"
],
"question": "What are the titles of albums by the artist \"AC/DC\"?",
"question_toks": [
"What",
"are",
"the",
"titles",
"of",
"albums",
"by",
"the",
"artist",
"``",
"AC/DC",
"''",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
3,
false
],
null
],
[
0,
4,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
1
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
2,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
5,
false
],
null
],
"\"AC/DC\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT COUNT(*) FROM ALBUM AS T1 JOIN ARTIST AS T2 ON T1.ArtistId = T2.ArtistId WHERE T2.Name = \"Metallica\"",
"query_toks": [
"SELECT",
"COUNT",
"(",
"*",
")",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"ARTIST",
"AS",
"T2",
"ON",
"T1.ArtistId",
"=",
"T2.ArtistId",
"WHERE",
"T2.Name",
"=",
"``",
"Metallica",
"''"
],
"query_toks_no_value": [
"select",
"count",
"(",
"*",
")",
"from",
"album",
"as",
"t1",
"join",
"artist",
"as",
"t2",
"on",
"t1",
".",
"artistid",
"=",
"t2",
".",
"artistid",
"where",
"t2",
".",
"name",
"=",
"value"
],
"question": "Hom many albums does the artist \"Metallica\" have?",
"question_toks": [
"Hom",
"many",
"albums",
"does",
"the",
"artist",
"``",
"Metallica",
"''",
"have",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
3,
false
],
null
],
[
0,
4,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
1
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
3,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
5,
false
],
null
],
"\"Metallica\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT COUNT(*) FROM ALBUM AS T1 JOIN ARTIST AS T2 ON T1.ArtistId = T2.ArtistId WHERE T2.Name = \"Metallica\"",
"query_toks": [
"SELECT",
"COUNT",
"(",
"*",
")",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"ARTIST",
"AS",
"T2",
"ON",
"T1.ArtistId",
"=",
"T2.ArtistId",
"WHERE",
"T2.Name",
"=",
"``",
"Metallica",
"''"
],
"query_toks_no_value": [
"select",
"count",
"(",
"*",
")",
"from",
"album",
"as",
"t1",
"join",
"artist",
"as",
"t2",
"on",
"t1",
".",
"artistid",
"=",
"t2",
".",
"artistid",
"where",
"t2",
".",
"name",
"=",
"value"
],
"question": "Find the number of albums by the artist \"Metallica\".",
"question_toks": [
"Find",
"the",
"number",
"of",
"albums",
"by",
"the",
"artist",
"``",
"Metallica",
"''",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
3,
false
],
null
],
[
0,
4,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
1
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
3,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
5,
false
],
null
],
"\"Metallica\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT T2.Name FROM ALBUM AS T1 JOIN ARTIST AS T2 ON T1.ArtistId = T2.ArtistId WHERE T1.Title = \"Balls to the Wall\"",
"query_toks": [
"SELECT",
"T2.Name",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"ARTIST",
"AS",
"T2",
"ON",
"T1.ArtistId",
"=",
"T2.ArtistId",
"WHERE",
"T1.Title",
"=",
"``",
"Balls",
"to",
"the",
"Wall",
"''"
],
"query_toks_no_value": [
"select",
"t2",
".",
"name",
"from",
"album",
"as",
"t1",
"join",
"artist",
"as",
"t2",
"on",
"t1",
".",
"artistid",
"=",
"t2",
".",
"artistid",
"where",
"t1",
".",
"title",
"=",
"value"
],
"question": "Which artist does the album \"Balls to the Wall\" belong to?",
"question_toks": [
"Which",
"artist",
"does",
"the",
"album",
"``",
"Balls",
"to",
"the",
"Wall",
"''",
"belong",
"to",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
3,
false
],
null
],
[
0,
4,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
1
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
5,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
2,
false
],
null
],
"\"Balls to the Wall\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT T2.Name FROM ALBUM AS T1 JOIN ARTIST AS T2 ON T1.ArtistId = T2.ArtistId WHERE T1.Title = \"Balls to the Wall\"",
"query_toks": [
"SELECT",
"T2.Name",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"ARTIST",
"AS",
"T2",
"ON",
"T1.ArtistId",
"=",
"T2.ArtistId",
"WHERE",
"T1.Title",
"=",
"``",
"Balls",
"to",
"the",
"Wall",
"''"
],
"query_toks_no_value": [
"select",
"t2",
".",
"name",
"from",
"album",
"as",
"t1",
"join",
"artist",
"as",
"t2",
"on",
"t1",
".",
"artistid",
"=",
"t2",
".",
"artistid",
"where",
"t1",
".",
"title",
"=",
"value"
],
"question": "Find the name of the artist who made the album \"Balls to the Wall\".",
"question_toks": [
"Find",
"the",
"name",
"of",
"the",
"artist",
"who",
"made",
"the",
"album",
"``",
"Balls",
"to",
"the",
"Wall",
"''",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
3,
false
],
null
],
[
0,
4,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
1
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
5,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
2,
false
],
null
],
"\"Balls to the Wall\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT T2.Name FROM ALBUM AS T1 JOIN ARTIST AS T2 ON T1.ArtistId = T2.ArtistId GROUP BY T2.Name ORDER BY COUNT(*) DESC LIMIT 1",
"query_toks": [
"SELECT",
"T2.Name",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"ARTIST",
"AS",
"T2",
"ON",
"T1.ArtistId",
"=",
"T2.ArtistId",
"GROUP",
"BY",
"T2.Name",
"ORDER",
"BY",
"COUNT",
"(",
"*",
")",
"DESC",
"LIMIT",
"1"
],
"query_toks_no_value": [
"select",
"t2",
".",
"name",
"from",
"album",
"as",
"t1",
"join",
"artist",
"as",
"t2",
"on",
"t1",
".",
"artistid",
"=",
"t2",
".",
"artistid",
"group",
"by",
"t2",
".",
"name",
"order",
"by",
"count",
"(",
"*",
")",
"desc",
"limit",
"value"
],
"question": "Which artist has the most albums?",
"question_toks": [
"Which",
"artist",
"has",
"the",
"most",
"albums",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
3,
false
],
null
],
[
0,
4,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
1
]
]
},
"groupBy": [
[
0,
5,
false
]
],
"having": [],
"intersect": null,
"limit": 1,
"orderBy": [
"desc",
[
[
0,
[
3,
0,
false
],
null
]
]
],
"select": [
false,
[
[
0,
[
0,
[
0,
5,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT T2.Name FROM ALBUM AS T1 JOIN ARTIST AS T2 ON T1.ArtistId = T2.ArtistId GROUP BY T2.Name ORDER BY COUNT(*) DESC LIMIT 1",
"query_toks": [
"SELECT",
"T2.Name",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"ARTIST",
"AS",
"T2",
"ON",
"T1.ArtistId",
"=",
"T2.ArtistId",
"GROUP",
"BY",
"T2.Name",
"ORDER",
"BY",
"COUNT",
"(",
"*",
")",
"DESC",
"LIMIT",
"1"
],
"query_toks_no_value": [
"select",
"t2",
".",
"name",
"from",
"album",
"as",
"t1",
"join",
"artist",
"as",
"t2",
"on",
"t1",
".",
"artistid",
"=",
"t2",
".",
"artistid",
"group",
"by",
"t2",
".",
"name",
"order",
"by",
"count",
"(",
"*",
")",
"desc",
"limit",
"value"
],
"question": "What is the name of the artist with the greatest number of albums?",
"question_toks": [
"What",
"is",
"the",
"name",
"of",
"the",
"artist",
"with",
"the",
"greatest",
"number",
"of",
"albums",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
3,
false
],
null
],
[
0,
4,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
1
]
]
},
"groupBy": [
[
0,
5,
false
]
],
"having": [],
"intersect": null,
"limit": 1,
"orderBy": [
"desc",
[
[
0,
[
3,
0,
false
],
null
]
]
],
"select": [
false,
[
[
0,
[
0,
[
0,
5,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT Name FROM TRACK WHERE Name LIKE '%you%'",
"query_toks": [
"SELECT",
"Name",
"FROM",
"TRACK",
"WHERE",
"Name",
"LIKE",
"'",
"%",
"you",
"%",
"'"
],
"query_toks_no_value": [
"select",
"name",
"from",
"track",
"where",
"name",
"like",
"value"
],
"question": "Find the names of all the tracks that contain the word \"you\".",
"question_toks": [
"Find",
"the",
"names",
"of",
"all",
"the",
"tracks",
"that",
"contain",
"the",
"word",
"``",
"you",
"''",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
57,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
9,
[
0,
[
0,
57,
false
],
null
],
"\"%you%\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT Name FROM TRACK WHERE Name LIKE '%you%'",
"query_toks": [
"SELECT",
"Name",
"FROM",
"TRACK",
"WHERE",
"Name",
"LIKE",
"'",
"%",
"you",
"%",
"'"
],
"query_toks_no_value": [
"select",
"name",
"from",
"track",
"where",
"name",
"like",
"value"
],
"question": "What are the names of tracks that contain the the word you in them?",
"question_toks": [
"What",
"are",
"the",
"names",
"of",
"tracks",
"that",
"contain",
"the",
"the",
"word",
"you",
"in",
"them",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
57,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
9,
[
0,
[
0,
57,
false
],
null
],
"\"%you%\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT AVG(UnitPrice) FROM TRACK",
"query_toks": [
"SELECT",
"AVG",
"(",
"UnitPrice",
")",
"FROM",
"TRACK"
],
"query_toks_no_value": [
"select",
"avg",
"(",
"unitprice",
")",
"from",
"track"
],
"question": "What is the average unit price of all the tracks?",
"question_toks": [
"What",
"is",
"the",
"average",
"unit",
"price",
"of",
"all",
"the",
"tracks",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
5,
[
0,
[
0,
64,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT AVG(UnitPrice) FROM TRACK",
"query_toks": [
"SELECT",
"AVG",
"(",
"UnitPrice",
")",
"FROM",
"TRACK"
],
"query_toks_no_value": [
"select",
"avg",
"(",
"unitprice",
")",
"from",
"track"
],
"question": "Find the average unit price for a track.",
"question_toks": [
"Find",
"the",
"average",
"unit",
"price",
"for",
"a",
"track",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
5,
[
0,
[
0,
64,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT max(Milliseconds) , min(Milliseconds) FROM TRACK",
"query_toks": [
"SELECT",
"max",
"(",
"Milliseconds",
")",
",",
"min",
"(",
"Milliseconds",
")",
"FROM",
"TRACK"
],
"query_toks_no_value": [
"select",
"max",
"(",
"milliseconds",
")",
",",
"min",
"(",
"milliseconds",
")",
"from",
"track"
],
"question": "What are the durations of the longest and the shortest tracks in milliseconds?",
"question_toks": [
"What",
"are",
"the",
"durations",
"of",
"the",
"longest",
"and",
"the",
"shortest",
"tracks",
"in",
"milliseconds",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
1,
[
0,
[
0,
62,
false
],
null
]
],
[
2,
[
0,
[
0,
62,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT max(Milliseconds) , min(Milliseconds) FROM TRACK",
"query_toks": [
"SELECT",
"max",
"(",
"Milliseconds",
")",
",",
"min",
"(",
"Milliseconds",
")",
"FROM",
"TRACK"
],
"query_toks_no_value": [
"select",
"max",
"(",
"milliseconds",
")",
",",
"min",
"(",
"milliseconds",
")",
"from",
"track"
],
"question": "Find the maximum and minimum durations of tracks in milliseconds.",
"question_toks": [
"Find",
"the",
"maximum",
"and",
"minimum",
"durations",
"of",
"tracks",
"in",
"milliseconds",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
1,
[
0,
[
0,
62,
false
],
null
]
],
[
2,
[
0,
[
0,
62,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT T1.Title , T2.AlbumID , COUNT(*) FROM ALBUM AS T1 JOIN TRACK AS T2 ON T1.AlbumId = T2.AlbumId GROUP BY T2.AlbumID",
"query_toks": [
"SELECT",
"T1.Title",
",",
"T2.AlbumID",
",",
"COUNT",
"(",
"*",
")",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.AlbumId",
"=",
"T2.AlbumId",
"GROUP",
"BY",
"T2.AlbumID"
],
"query_toks_no_value": [
"select",
"t1",
".",
"title",
",",
"t2",
".",
"albumid",
",",
"count",
"(",
"*",
")",
"from",
"album",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"albumid",
"=",
"t2",
".",
"albumid",
"group",
"by",
"t2",
".",
"albumid"
],
"question": "Show the album names, ids and the number of tracks for each album.",
"question_toks": [
"Show",
"the",
"album",
"names",
",",
"ids",
"and",
"the",
"number",
"of",
"tracks",
"for",
"each",
"album",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
1,
false
],
null
],
[
0,
58,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
10
]
]
},
"groupBy": [
[
0,
58,
false
]
],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
2,
false
],
null
]
],
[
0,
[
0,
[
0,
58,
false
],
null
]
],
[
3,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT T1.Title , T2.AlbumID , COUNT(*) FROM ALBUM AS T1 JOIN TRACK AS T2 ON T1.AlbumId = T2.AlbumId GROUP BY T2.AlbumID",
"query_toks": [
"SELECT",
"T1.Title",
",",
"T2.AlbumID",
",",
"COUNT",
"(",
"*",
")",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.AlbumId",
"=",
"T2.AlbumId",
"GROUP",
"BY",
"T2.AlbumID"
],
"query_toks_no_value": [
"select",
"t1",
".",
"title",
",",
"t2",
".",
"albumid",
",",
"count",
"(",
"*",
")",
"from",
"album",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"albumid",
"=",
"t2",
".",
"albumid",
"group",
"by",
"t2",
".",
"albumid"
],
"question": "What are the names and ids of the different albums, and how many tracks are on each?",
"question_toks": [
"What",
"are",
"the",
"names",
"and",
"ids",
"of",
"the",
"different",
"albums",
",",
"and",
"how",
"many",
"tracks",
"are",
"on",
"each",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
1,
false
],
null
],
[
0,
58,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
10
]
]
},
"groupBy": [
[
0,
58,
false
]
],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
2,
false
],
null
]
],
[
0,
[
0,
[
0,
58,
false
],
null
]
],
[
3,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT T1.Name FROM GENRE AS T1 JOIN TRACK AS T2 ON T1.GenreId = T2.GenreId GROUP BY T2.GenreId ORDER BY COUNT(*) DESC LIMIT 1",
"query_toks": [
"SELECT",
"T1.Name",
"FROM",
"GENRE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.GenreId",
"=",
"T2.GenreId",
"GROUP",
"BY",
"T2.GenreId",
"ORDER",
"BY",
"COUNT",
"(",
"*",
")",
"DESC",
"LIMIT",
"1"
],
"query_toks_no_value": [
"select",
"t1",
".",
"name",
"from",
"genre",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"genreid",
"=",
"t2",
".",
"genreid",
"group",
"by",
"t2",
".",
"genreid",
"order",
"by",
"count",
"(",
"*",
")",
"desc",
"limit",
"value"
],
"question": "What is the name of the most common genre in all tracks?",
"question_toks": [
"What",
"is",
"the",
"name",
"of",
"the",
"most",
"common",
"genre",
"in",
"all",
"tracks",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
34,
false
],
null
],
[
0,
60,
false
],
null
]
],
"table_units": [
[
"table_unit",
4
],
[
"table_unit",
10
]
]
},
"groupBy": [
[
0,
60,
false
]
],
"having": [],
"intersect": null,
"limit": 1,
"orderBy": [
"desc",
[
[
0,
[
3,
0,
false
],
null
]
]
],
"select": [
false,
[
[
0,
[
0,
[
0,
35,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT T1.Name FROM GENRE AS T1 JOIN TRACK AS T2 ON T1.GenreId = T2.GenreId GROUP BY T2.GenreId ORDER BY COUNT(*) DESC LIMIT 1",
"query_toks": [
"SELECT",
"T1.Name",
"FROM",
"GENRE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.GenreId",
"=",
"T2.GenreId",
"GROUP",
"BY",
"T2.GenreId",
"ORDER",
"BY",
"COUNT",
"(",
"*",
")",
"DESC",
"LIMIT",
"1"
],
"query_toks_no_value": [
"select",
"t1",
".",
"name",
"from",
"genre",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"genreid",
"=",
"t2",
".",
"genreid",
"group",
"by",
"t2",
".",
"genreid",
"order",
"by",
"count",
"(",
"*",
")",
"desc",
"limit",
"value"
],
"question": "Find the name of the genre that is most frequent across all tracks.",
"question_toks": [
"Find",
"the",
"name",
"of",
"the",
"genre",
"that",
"is",
"most",
"frequent",
"across",
"all",
"tracks",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
34,
false
],
null
],
[
0,
60,
false
],
null
]
],
"table_units": [
[
"table_unit",
4
],
[
"table_unit",
10
]
]
},
"groupBy": [
[
0,
60,
false
]
],
"having": [],
"intersect": null,
"limit": 1,
"orderBy": [
"desc",
[
[
0,
[
3,
0,
false
],
null
]
]
],
"select": [
false,
[
[
0,
[
0,
[
0,
35,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT T1.Name FROM MEDIATYPE AS T1 JOIN TRACK AS T2 ON T1.MediaTypeId = T2.MediaTypeId GROUP BY T2.MediaTypeId ORDER BY COUNT(*) ASC LIMIT 1",
"query_toks": [
"SELECT",
"T1.Name",
"FROM",
"MEDIATYPE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.MediaTypeId",
"=",
"T2.MediaTypeId",
"GROUP",
"BY",
"T2.MediaTypeId",
"ORDER",
"BY",
"COUNT",
"(",
"*",
")",
"ASC",
"LIMIT",
"1"
],
"query_toks_no_value": [
"select",
"t1",
".",
"name",
"from",
"mediatype",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"mediatypeid",
"=",
"t2",
".",
"mediatypeid",
"group",
"by",
"t2",
".",
"mediatypeid",
"order",
"by",
"count",
"(",
"*",
")",
"asc",
"limit",
"value"
],
"question": "What is the least common media type in all tracks?",
"question_toks": [
"What",
"is",
"the",
"least",
"common",
"media",
"type",
"in",
"all",
"tracks",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
50,
false
],
null
],
[
0,
59,
false
],
null
]
],
"table_units": [
[
"table_unit",
7
],
[
"table_unit",
10
]
]
},
"groupBy": [
[
0,
59,
false
]
],
"having": [],
"intersect": null,
"limit": 1,
"orderBy": [
"asc",
[
[
0,
[
3,
0,
false
],
null
]
]
],
"select": [
false,
[
[
0,
[
0,
[
0,
51,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT T1.Name FROM MEDIATYPE AS T1 JOIN TRACK AS T2 ON T1.MediaTypeId = T2.MediaTypeId GROUP BY T2.MediaTypeId ORDER BY COUNT(*) ASC LIMIT 1",
"query_toks": [
"SELECT",
"T1.Name",
"FROM",
"MEDIATYPE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.MediaTypeId",
"=",
"T2.MediaTypeId",
"GROUP",
"BY",
"T2.MediaTypeId",
"ORDER",
"BY",
"COUNT",
"(",
"*",
")",
"ASC",
"LIMIT",
"1"
],
"query_toks_no_value": [
"select",
"t1",
".",
"name",
"from",
"mediatype",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"mediatypeid",
"=",
"t2",
".",
"mediatypeid",
"group",
"by",
"t2",
".",
"mediatypeid",
"order",
"by",
"count",
"(",
"*",
")",
"asc",
"limit",
"value"
],
"question": "What is the name of the media type that is least common across all tracks?",
"question_toks": [
"What",
"is",
"the",
"name",
"of",
"the",
"media",
"type",
"that",
"is",
"least",
"common",
"across",
"all",
"tracks",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
50,
false
],
null
],
[
0,
59,
false
],
null
]
],
"table_units": [
[
"table_unit",
7
],
[
"table_unit",
10
]
]
},
"groupBy": [
[
0,
59,
false
]
],
"having": [],
"intersect": null,
"limit": 1,
"orderBy": [
"asc",
[
[
0,
[
3,
0,
false
],
null
]
]
],
"select": [
false,
[
[
0,
[
0,
[
0,
51,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT T1.Title , T2.AlbumID FROM ALBUM AS T1 JOIN TRACK AS T2 ON T1.AlbumId = T2.AlbumId WHERE T2.UnitPrice > 1 GROUP BY T2.AlbumID",
"query_toks": [
"SELECT",
"T1.Title",
",",
"T2.AlbumID",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.AlbumId",
"=",
"T2.AlbumId",
"WHERE",
"T2.UnitPrice",
">",
"1",
"GROUP",
"BY",
"T2.AlbumID"
],
"query_toks_no_value": [
"select",
"t1",
".",
"title",
",",
"t2",
".",
"albumid",
"from",
"album",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"albumid",
"=",
"t2",
".",
"albumid",
"where",
"t2",
".",
"unitprice",
">",
"value",
"group",
"by",
"t2",
".",
"albumid"
],
"question": "Show the album names and ids for albums that contain tracks with unit price bigger than 1.",
"question_toks": [
"Show",
"the",
"album",
"names",
"and",
"ids",
"for",
"albums",
"that",
"contain",
"tracks",
"with",
"unit",
"price",
"bigger",
"than",
"1",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
1,
false
],
null
],
[
0,
58,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
10
]
]
},
"groupBy": [
[
0,
58,
false
]
],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
2,
false
],
null
]
],
[
0,
[
0,
[
0,
58,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
3,
[
0,
[
0,
64,
false
],
null
],
1.0,
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT T1.Title , T2.AlbumID FROM ALBUM AS T1 JOIN TRACK AS T2 ON T1.AlbumId = T2.AlbumId WHERE T2.UnitPrice > 1 GROUP BY T2.AlbumID",
"query_toks": [
"SELECT",
"T1.Title",
",",
"T2.AlbumID",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.AlbumId",
"=",
"T2.AlbumId",
"WHERE",
"T2.UnitPrice",
">",
"1",
"GROUP",
"BY",
"T2.AlbumID"
],
"query_toks_no_value": [
"select",
"t1",
".",
"title",
",",
"t2",
".",
"albumid",
"from",
"album",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"albumid",
"=",
"t2",
".",
"albumid",
"where",
"t2",
".",
"unitprice",
">",
"value",
"group",
"by",
"t2",
".",
"albumid"
],
"question": "What are the titles and ids for albums containing tracks with unit price greater than 1?",
"question_toks": [
"What",
"are",
"the",
"titles",
"and",
"ids",
"for",
"albums",
"containing",
"tracks",
"with",
"unit",
"price",
"greater",
"than",
"1",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
1,
false
],
null
],
[
0,
58,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
10
]
]
},
"groupBy": [
[
0,
58,
false
]
],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
2,
false
],
null
]
],
[
0,
[
0,
[
0,
58,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
3,
[
0,
[
0,
64,
false
],
null
],
1.0,
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT COUNT(*) FROM GENRE AS T1 JOIN TRACK AS T2 ON T1.GenreId = T2.GenreId WHERE T1.Name = \"Rock\"",
"query_toks": [
"SELECT",
"COUNT",
"(",
"*",
")",
"FROM",
"GENRE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.GenreId",
"=",
"T2.GenreId",
"WHERE",
"T1.Name",
"=",
"``",
"Rock",
"''"
],
"query_toks_no_value": [
"select",
"count",
"(",
"*",
")",
"from",
"genre",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"genreid",
"=",
"t2",
".",
"genreid",
"where",
"t1",
".",
"name",
"=",
"value"
],
"question": "How many tracks belong to rock genre?",
"question_toks": [
"How",
"many",
"tracks",
"belong",
"to",
"rock",
"genre",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
34,
false
],
null
],
[
0,
60,
false
],
null
]
],
"table_units": [
[
"table_unit",
4
],
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
3,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Rock\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT COUNT(*) FROM GENRE AS T1 JOIN TRACK AS T2 ON T1.GenreId = T2.GenreId WHERE T1.Name = \"Rock\"",
"query_toks": [
"SELECT",
"COUNT",
"(",
"*",
")",
"FROM",
"GENRE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.GenreId",
"=",
"T2.GenreId",
"WHERE",
"T1.Name",
"=",
"``",
"Rock",
"''"
],
"query_toks_no_value": [
"select",
"count",
"(",
"*",
")",
"from",
"genre",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"genreid",
"=",
"t2",
".",
"genreid",
"where",
"t1",
".",
"name",
"=",
"value"
],
"question": "Count the number of tracks that are part of the rock genre.",
"question_toks": [
"Count",
"the",
"number",
"of",
"tracks",
"that",
"are",
"part",
"of",
"the",
"rock",
"genre",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
34,
false
],
null
],
[
0,
60,
false
],
null
]
],
"table_units": [
[
"table_unit",
4
],
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
3,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Rock\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT AVG(UnitPrice) FROM GENRE AS T1 JOIN TRACK AS T2 ON T1.GenreId = T2.GenreId WHERE T1.Name = \"Jazz\"",
"query_toks": [
"SELECT",
"AVG",
"(",
"UnitPrice",
")",
"FROM",
"GENRE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.GenreId",
"=",
"T2.GenreId",
"WHERE",
"T1.Name",
"=",
"``",
"Jazz",
"''"
],
"query_toks_no_value": [
"select",
"avg",
"(",
"unitprice",
")",
"from",
"genre",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"genreid",
"=",
"t2",
".",
"genreid",
"where",
"t1",
".",
"name",
"=",
"value"
],
"question": "What is the average unit price of tracks that belong to Jazz genre?",
"question_toks": [
"What",
"is",
"the",
"average",
"unit",
"price",
"of",
"tracks",
"that",
"belong",
"to",
"Jazz",
"genre",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
34,
false
],
null
],
[
0,
60,
false
],
null
]
],
"table_units": [
[
"table_unit",
4
],
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
5,
[
0,
[
0,
64,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Jazz\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT AVG(UnitPrice) FROM GENRE AS T1 JOIN TRACK AS T2 ON T1.GenreId = T2.GenreId WHERE T1.Name = \"Jazz\"",
"query_toks": [
"SELECT",
"AVG",
"(",
"UnitPrice",
")",
"FROM",
"GENRE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.GenreId",
"=",
"T2.GenreId",
"WHERE",
"T1.Name",
"=",
"``",
"Jazz",
"''"
],
"query_toks_no_value": [
"select",
"avg",
"(",
"unitprice",
")",
"from",
"genre",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"genreid",
"=",
"t2",
".",
"genreid",
"where",
"t1",
".",
"name",
"=",
"value"
],
"question": "Find the average unit price of jazz tracks.",
"question_toks": [
"Find",
"the",
"average",
"unit",
"price",
"of",
"jazz",
"tracks",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
34,
false
],
null
],
[
0,
60,
false
],
null
]
],
"table_units": [
[
"table_unit",
4
],
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
5,
[
0,
[
0,
64,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Jazz\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT FirstName , LastName FROM CUSTOMER WHERE Email = \"luisg@embraer.com.br\"",
"query_toks": [
"SELECT",
"FirstName",
",",
"LastName",
"FROM",
"CUSTOMER",
"WHERE",
"Email",
"=",
"``",
"luisg",
"@",
"embraer.com.br",
"''"
],
"query_toks_no_value": [
"select",
"firstname",
",",
"lastname",
"from",
"customer",
"where",
"email",
"=",
"value"
],
"question": "What is the first name and last name of the customer that has email \"luisg@embraer.com.br\"?",
"question_toks": [
"What",
"is",
"the",
"first",
"name",
"and",
"last",
"name",
"of",
"the",
"customer",
"that",
"has",
"email",
"``",
"luisg",
"@",
"embraer.com.br",
"''",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
2
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
7,
false
],
null
]
],
[
0,
[
0,
[
0,
8,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
17,
false
],
null
],
"\"luisg@embraer.com.br\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT FirstName , LastName FROM CUSTOMER WHERE Email = \"luisg@embraer.com.br\"",
"query_toks": [
"SELECT",
"FirstName",
",",
"LastName",
"FROM",
"CUSTOMER",
"WHERE",
"Email",
"=",
"``",
"luisg",
"@",
"embraer.com.br",
"''"
],
"query_toks_no_value": [
"select",
"firstname",
",",
"lastname",
"from",
"customer",
"where",
"email",
"=",
"value"
],
"question": "Find the full name of the customer with the email \"luisg@embraer.com.br\".",
"question_toks": [
"Find",
"the",
"full",
"name",
"of",
"the",
"customer",
"with",
"the",
"email",
"``",
"luisg",
"@",
"embraer.com.br",
"''",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
2
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
7,
false
],
null
]
],
[
0,
[
0,
[
0,
8,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
17,
false
],
null
],
"\"luisg@embraer.com.br\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT COUNT(*) FROM CUSTOMER WHERE Email LIKE \"%gmail.com%\"",
"query_toks": [
"SELECT",
"COUNT",
"(",
"*",
")",
"FROM",
"CUSTOMER",
"WHERE",
"Email",
"LIKE",
"``",
"%",
"gmail.com",
"%",
"''"
],
"query_toks_no_value": [
"select",
"count",
"(",
"*",
")",
"from",
"customer",
"where",
"email",
"like",
"value"
],
"question": "How many customers have email that contains \"gmail.com\"?",
"question_toks": [
"How",
"many",
"customers",
"have",
"email",
"that",
"contains",
"``",
"gmail.com",
"''",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
2
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
3,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
9,
[
0,
[
0,
17,
false
],
null
],
"\"%gmail.com%\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT COUNT(*) FROM CUSTOMER WHERE Email LIKE \"%gmail.com%\"",
"query_toks": [
"SELECT",
"COUNT",
"(",
"*",
")",
"FROM",
"CUSTOMER",
"WHERE",
"Email",
"LIKE",
"``",
"%",
"gmail.com",
"%",
"''"
],
"query_toks_no_value": [
"select",
"count",
"(",
"*",
")",
"from",
"customer",
"where",
"email",
"like",
"value"
],
"question": "Count the number of customers that have an email containing \"gmail.com\".",
"question_toks": [
"Count",
"the",
"number",
"of",
"customers",
"that",
"have",
"an",
"email",
"containing",
"``",
"gmail.com",
"''",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
2
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
3,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
9,
[
0,
[
0,
17,
false
],
null
],
"\"%gmail.com%\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT T2.FirstName , T2.LastName FROM CUSTOMER AS T1 JOIN EMPLOYEE AS T2 ON T1.SupportRepId = T2.EmployeeId WHERE T1.FirstName = \"Leonie\"",
"query_toks": [
"SELECT",
"T2.FirstName",
",",
"T2.LastName",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"EMPLOYEE",
"AS",
"T2",
"ON",
"T1.SupportRepId",
"=",
"T2.EmployeeId",
"WHERE",
"T1.FirstName",
"=",
"``",
"Leonie",
"''"
],
"query_toks_no_value": [
"select",
"t2",
".",
"firstname",
",",
"t2",
".",
"lastname",
"from",
"customer",
"as",
"t1",
"join",
"employee",
"as",
"t2",
"on",
"t1",
".",
"supportrepid",
"=",
"t2",
".",
"employeeid",
"where",
"t1",
".",
"firstname",
"=",
"value"
],
"question": "What is the first name and last name employee helps the customer with first name Leonie?",
"question_toks": [
"What",
"is",
"the",
"first",
"name",
"and",
"last",
"name",
"employee",
"helps",
"the",
"customer",
"with",
"first",
"name",
"Leonie",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
18,
false
],
null
],
[
0,
19,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
3
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
21,
false
],
null
]
],
[
0,
[
0,
[
0,
20,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
7,
false
],
null
],
"\"Leonie\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT T2.FirstName , T2.LastName FROM CUSTOMER AS T1 JOIN EMPLOYEE AS T2 ON T1.SupportRepId = T2.EmployeeId WHERE T1.FirstName = \"Leonie\"",
"query_toks": [
"SELECT",
"T2.FirstName",
",",
"T2.LastName",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"EMPLOYEE",
"AS",
"T2",
"ON",
"T1.SupportRepId",
"=",
"T2.EmployeeId",
"WHERE",
"T1.FirstName",
"=",
"``",
"Leonie",
"''"
],
"query_toks_no_value": [
"select",
"t2",
".",
"firstname",
",",
"t2",
".",
"lastname",
"from",
"customer",
"as",
"t1",
"join",
"employee",
"as",
"t2",
"on",
"t1",
".",
"supportrepid",
"=",
"t2",
".",
"employeeid",
"where",
"t1",
".",
"firstname",
"=",
"value"
],
"question": "Find the full names of employees who help customers with the first name Leonie.",
"question_toks": [
"Find",
"the",
"full",
"names",
"of",
"employees",
"who",
"help",
"customers",
"with",
"the",
"first",
"name",
"Leonie",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
18,
false
],
null
],
[
0,
19,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
3
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
21,
false
],
null
]
],
[
0,
[
0,
[
0,
20,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
7,
false
],
null
],
"\"Leonie\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT T2.City FROM CUSTOMER AS T1 JOIN EMPLOYEE AS T2 ON T1.SupportRepId = T2.EmployeeId WHERE T1.PostalCode = \"70174\"",
"query_toks": [
"SELECT",
"T2.City",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"EMPLOYEE",
"AS",
"T2",
"ON",
"T1.SupportRepId",
"=",
"T2.EmployeeId",
"WHERE",
"T1.PostalCode",
"=",
"``",
"70174",
"''"
],
"query_toks_no_value": [
"select",
"t2",
".",
"city",
"from",
"customer",
"as",
"t1",
"join",
"employee",
"as",
"t2",
"on",
"t1",
".",
"supportrepid",
"=",
"t2",
".",
"employeeid",
"where",
"t1",
".",
"postalcode",
"=",
"value"
],
"question": "What city does the employee who helps the customer with postal code 70174 live in?",
"question_toks": [
"What",
"city",
"does",
"the",
"employee",
"who",
"helps",
"the",
"customer",
"with",
"postal",
"code",
"70174",
"live",
"in",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
18,
false
],
null
],
[
0,
19,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
3
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
27,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
14,
false
],
null
],
"\"70174\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT T2.City FROM CUSTOMER AS T1 JOIN EMPLOYEE AS T2 ON T1.SupportRepId = T2.EmployeeId WHERE T1.PostalCode = \"70174\"",
"query_toks": [
"SELECT",
"T2.City",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"EMPLOYEE",
"AS",
"T2",
"ON",
"T1.SupportRepId",
"=",
"T2.EmployeeId",
"WHERE",
"T1.PostalCode",
"=",
"``",
"70174",
"''"
],
"query_toks_no_value": [
"select",
"t2",
".",
"city",
"from",
"customer",
"as",
"t1",
"join",
"employee",
"as",
"t2",
"on",
"t1",
".",
"supportrepid",
"=",
"t2",
".",
"employeeid",
"where",
"t1",
".",
"postalcode",
"=",
"value"
],
"question": "Find the cities corresponding to employees who help customers with the postal code 70174.",
"question_toks": [
"Find",
"the",
"cities",
"corresponding",
"to",
"employees",
"who",
"help",
"customers",
"with",
"the",
"postal",
"code",
"70174",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
18,
false
],
null
],
[
0,
19,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
3
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
27,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
14,
false
],
null
],
"\"70174\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT COUNT(DISTINCT city) FROM EMPLOYEE",
"query_toks": [
"SELECT",
"COUNT",
"(",
"DISTINCT",
"city",
")",
"FROM",
"EMPLOYEE"
],
"query_toks_no_value": [
"select",
"count",
"(",
"distinct",
"city",
")",
"from",
"employee"
],
"question": "How many distinct cities does the employees live in?",
"question_toks": [
"How",
"many",
"distinct",
"cities",
"does",
"the",
"employees",
"live",
"in",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
3
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
3,
[
0,
[
0,
27,
true
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT COUNT(DISTINCT city) FROM EMPLOYEE",
"query_toks": [
"SELECT",
"COUNT",
"(",
"DISTINCT",
"city",
")",
"FROM",
"EMPLOYEE"
],
"query_toks_no_value": [
"select",
"count",
"(",
"distinct",
"city",
")",
"from",
"employee"
],
"question": "Find the number of different cities that employees live in.",
"question_toks": [
"Find",
"the",
"number",
"of",
"different",
"cities",
"that",
"employees",
"live",
"in",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
3
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
3,
[
0,
[
0,
27,
true
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT T2.InvoiceDate FROM CUSTOMER AS T1 JOIN INVOICE AS T2 ON T1.CustomerId = T2.CustomerId WHERE T1.FirstName = \"Astrid\" AND LastName = \"Gruber\"",
"query_toks": [
"SELECT",
"T2.InvoiceDate",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"INVOICE",
"AS",
"T2",
"ON",
"T1.CustomerId",
"=",
"T2.CustomerId",
"WHERE",
"T1.FirstName",
"=",
"``",
"Astrid",
"''",
"AND",
"LastName",
"=",
"``",
"Gruber",
"''"
],
"query_toks_no_value": [
"select",
"t2",
".",
"invoicedate",
"from",
"customer",
"as",
"t1",
"join",
"invoice",
"as",
"t2",
"on",
"t1",
".",
"customerid",
"=",
"t2",
".",
"customerid",
"where",
"t1",
".",
"firstname",
"=",
"value",
"and",
"lastname",
"=",
"value"
],
"question": "Find all invoice dates corresponding to customers with first name Astrid and last name Gruber.",
"question_toks": [
"Find",
"all",
"invoice",
"dates",
"corresponding",
"to",
"customers",
"with",
"first",
"name",
"Astrid",
"and",
"last",
"name",
"Gruber",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
6,
false
],
null
],
[
0,
37,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
5
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
38,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
7,
false
],
null
],
"\"Astrid\"",
null
],
"and",
[
false,
2,
[
0,
[
0,
8,
false
],
null
],
"\"Gruber\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT T2.InvoiceDate FROM CUSTOMER AS T1 JOIN INVOICE AS T2 ON T1.CustomerId = T2.CustomerId WHERE T1.FirstName = \"Astrid\" AND LastName = \"Gruber\"",
"query_toks": [
"SELECT",
"T2.InvoiceDate",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"INVOICE",
"AS",
"T2",
"ON",
"T1.CustomerId",
"=",
"T2.CustomerId",
"WHERE",
"T1.FirstName",
"=",
"``",
"Astrid",
"''",
"AND",
"LastName",
"=",
"``",
"Gruber",
"''"
],
"query_toks_no_value": [
"select",
"t2",
".",
"invoicedate",
"from",
"customer",
"as",
"t1",
"join",
"invoice",
"as",
"t2",
"on",
"t1",
".",
"customerid",
"=",
"t2",
".",
"customerid",
"where",
"t1",
".",
"firstname",
"=",
"value",
"and",
"lastname",
"=",
"value"
],
"question": "What are the invoice dates for customers with the first name Astrid and the last name Gruber?",
"question_toks": [
"What",
"are",
"the",
"invoice",
"dates",
"for",
"customers",
"with",
"the",
"first",
"name",
"Astrid",
"and",
"the",
"last",
"name",
"Gruber",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
6,
false
],
null
],
[
0,
37,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
5
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
38,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
7,
false
],
null
],
"\"Astrid\"",
null
],
"and",
[
false,
2,
[
0,
[
0,
8,
false
],
null
],
"\"Gruber\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT LastName FROM CUSTOMER EXCEPT SELECT T1.LastName FROM CUSTOMER AS T1 JOIN Invoice AS T2 ON T1.CustomerId = T2.CustomerId WHERE T2.total > 20",
"query_toks": [
"SELECT",
"LastName",
"FROM",
"CUSTOMER",
"EXCEPT",
"SELECT",
"T1.LastName",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"Invoice",
"AS",
"T2",
"ON",
"T1.CustomerId",
"=",
"T2.CustomerId",
"WHERE",
"T2.total",
">",
"20"
],
"query_toks_no_value": [
"select",
"lastname",
"from",
"customer",
"except",
"select",
"t1",
".",
"lastname",
"from",
"customer",
"as",
"t1",
"join",
"invoice",
"as",
"t2",
"on",
"t1",
".",
"customerid",
"=",
"t2",
".",
"customerid",
"where",
"t2",
".",
"total",
">",
"value"
],
"question": "Find all the customer last names that do not have invoice totals larger than 20.",
"question_toks": [
"Find",
"all",
"the",
"customer",
"last",
"names",
"that",
"do",
"not",
"have",
"invoice",
"totals",
"larger",
"than",
"20",
"."
],
"sql": {
"except": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
6,
false
],
null
],
[
0,
37,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
5
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
8,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
3,
[
0,
[
0,
44,
false
],
null
],
20.0,
null
]
]
},
"from": {
"conds": [],
"table_units": [
[
"table_unit",
2
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
8,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT LastName FROM CUSTOMER EXCEPT SELECT T1.LastName FROM CUSTOMER AS T1 JOIN Invoice AS T2 ON T1.CustomerId = T2.CustomerId WHERE T2.total > 20",
"query_toks": [
"SELECT",
"LastName",
"FROM",
"CUSTOMER",
"EXCEPT",
"SELECT",
"T1.LastName",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"Invoice",
"AS",
"T2",
"ON",
"T1.CustomerId",
"=",
"T2.CustomerId",
"WHERE",
"T2.total",
">",
"20"
],
"query_toks_no_value": [
"select",
"lastname",
"from",
"customer",
"except",
"select",
"t1",
".",
"lastname",
"from",
"customer",
"as",
"t1",
"join",
"invoice",
"as",
"t2",
"on",
"t1",
".",
"customerid",
"=",
"t2",
".",
"customerid",
"where",
"t2",
".",
"total",
">",
"value"
],
"question": "What are the last names of customers without invoice totals exceeding 20?",
"question_toks": [
"What",
"are",
"the",
"last",
"names",
"of",
"customers",
"without",
"invoice",
"totals",
"exceeding",
"20",
"?"
],
"sql": {
"except": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
6,
false
],
null
],
[
0,
37,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
5
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
8,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
3,
[
0,
[
0,
44,
false
],
null
],
20.0,
null
]
]
},
"from": {
"conds": [],
"table_units": [
[
"table_unit",
2
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
8,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT DISTINCT T1.FirstName FROM CUSTOMER AS T1 JOIN INVOICE AS T2 ON T1.CustomerId = T2.CustomerId WHERE T1.country = \"Brazil\"",
"query_toks": [
"SELECT",
"DISTINCT",
"T1.FirstName",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"INVOICE",
"AS",
"T2",
"ON",
"T1.CustomerId",
"=",
"T2.CustomerId",
"WHERE",
"T1.country",
"=",
"``",
"Brazil",
"''"
],
"query_toks_no_value": [
"select",
"distinct",
"t1",
".",
"firstname",
"from",
"customer",
"as",
"t1",
"join",
"invoice",
"as",
"t2",
"on",
"t1",
".",
"customerid",
"=",
"t2",
".",
"customerid",
"where",
"t1",
".",
"country",
"=",
"value"
],
"question": "Find the first names of all customers that live in Brazil and have an invoice.",
"question_toks": [
"Find",
"the",
"first",
"names",
"of",
"all",
"customers",
"that",
"live",
"in",
"Brazil",
"and",
"have",
"an",
"invoice",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
6,
false
],
null
],
[
0,
37,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
5
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
true,
[
[
0,
[
0,
[
0,
7,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
13,
false
],
null
],
"\"Brazil\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT DISTINCT T1.FirstName FROM CUSTOMER AS T1 JOIN INVOICE AS T2 ON T1.CustomerId = T2.CustomerId WHERE T1.country = \"Brazil\"",
"query_toks": [
"SELECT",
"DISTINCT",
"T1.FirstName",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"INVOICE",
"AS",
"T2",
"ON",
"T1.CustomerId",
"=",
"T2.CustomerId",
"WHERE",
"T1.country",
"=",
"``",
"Brazil",
"''"
],
"query_toks_no_value": [
"select",
"distinct",
"t1",
".",
"firstname",
"from",
"customer",
"as",
"t1",
"join",
"invoice",
"as",
"t2",
"on",
"t1",
".",
"customerid",
"=",
"t2",
".",
"customerid",
"where",
"t1",
".",
"country",
"=",
"value"
],
"question": "What are the different first names for customers from Brazil who have also had an invoice?",
"question_toks": [
"What",
"are",
"the",
"different",
"first",
"names",
"for",
"customers",
"from",
"Brazil",
"who",
"have",
"also",
"had",
"an",
"invoice",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
6,
false
],
null
],
[
0,
37,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
5
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
true,
[
[
0,
[
0,
[
0,
7,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
13,
false
],
null
],
"\"Brazil\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT DISTINCT T1.Address FROM CUSTOMER AS T1 JOIN INVOICE AS T2 ON T1.CustomerId = T2.CustomerId WHERE T1.country = \"Germany\"",
"query_toks": [
"SELECT",
"DISTINCT",
"T1.Address",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"INVOICE",
"AS",
"T2",
"ON",
"T1.CustomerId",
"=",
"T2.CustomerId",
"WHERE",
"T1.country",
"=",
"``",
"Germany",
"''"
],
"query_toks_no_value": [
"select",
"distinct",
"t1",
".",
"address",
"from",
"customer",
"as",
"t1",
"join",
"invoice",
"as",
"t2",
"on",
"t1",
".",
"customerid",
"=",
"t2",
".",
"customerid",
"where",
"t1",
".",
"country",
"=",
"value"
],
"question": "Find the address of all customers that live in Germany and have invoice.",
"question_toks": [
"Find",
"the",
"address",
"of",
"all",
"customers",
"that",
"live",
"in",
"Germany",
"and",
"have",
"invoice",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
6,
false
],
null
],
[
0,
37,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
5
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
true,
[
[
0,
[
0,
[
0,
10,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
13,
false
],
null
],
"\"Germany\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT DISTINCT T1.Address FROM CUSTOMER AS T1 JOIN INVOICE AS T2 ON T1.CustomerId = T2.CustomerId WHERE T1.country = \"Germany\"",
"query_toks": [
"SELECT",
"DISTINCT",
"T1.Address",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"INVOICE",
"AS",
"T2",
"ON",
"T1.CustomerId",
"=",
"T2.CustomerId",
"WHERE",
"T1.country",
"=",
"``",
"Germany",
"''"
],
"query_toks_no_value": [
"select",
"distinct",
"t1",
".",
"address",
"from",
"customer",
"as",
"t1",
"join",
"invoice",
"as",
"t2",
"on",
"t1",
".",
"customerid",
"=",
"t2",
".",
"customerid",
"where",
"t1",
".",
"country",
"=",
"value"
],
"question": "What are the addresses of customers living in Germany who have had an invoice?",
"question_toks": [
"What",
"are",
"the",
"addresses",
"of",
"customers",
"living",
"in",
"Germany",
"who",
"have",
"had",
"an",
"invoice",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
6,
false
],
null
],
[
0,
37,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
5
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
true,
[
[
0,
[
0,
[
0,
10,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
13,
false
],
null
],
"\"Germany\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT Phone FROM EMPLOYEE",
"query_toks": [
"SELECT",
"Phone",
"FROM",
"EMPLOYEE"
],
"query_toks_no_value": [
"select",
"phone",
"from",
"employee"
],
"question": "List the phone numbers of all employees.",
"question_toks": [
"List",
"the",
"phone",
"numbers",
"of",
"all",
"employees",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
3
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
31,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT Phone FROM EMPLOYEE",
"query_toks": [
"SELECT",
"Phone",
"FROM",
"EMPLOYEE"
],
"query_toks_no_value": [
"select",
"phone",
"from",
"employee"
],
"question": "What are the phone numbers for each employee?",
"question_toks": [
"What",
"are",
"the",
"phone",
"numbers",
"for",
"each",
"employee",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
3
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
31,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT COUNT(*) FROM MEDIATYPE AS T1 JOIN TRACK AS T2 ON T1.MediaTypeId = T2.MediaTypeId WHERE T1.Name = \"AAC audio file\"",
"query_toks": [
"SELECT",
"COUNT",
"(",
"*",
")",
"FROM",
"MEDIATYPE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.MediaTypeId",
"=",
"T2.MediaTypeId",
"WHERE",
"T1.Name",
"=",
"``",
"AAC",
"audio",
"file",
"''"
],
"query_toks_no_value": [
"select",
"count",
"(",
"*",
")",
"from",
"mediatype",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"mediatypeid",
"=",
"t2",
".",
"mediatypeid",
"where",
"t1",
".",
"name",
"=",
"value"
],
"question": "How many tracks are in the AAC audio file media type?",
"question_toks": [
"How",
"many",
"tracks",
"are",
"in",
"the",
"AAC",
"audio",
"file",
"media",
"type",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
50,
false
],
null
],
[
0,
59,
false
],
null
]
],
"table_units": [
[
"table_unit",
7
],
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
3,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
51,
false
],
null
],
"\"AAC audio file\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT COUNT(*) FROM MEDIATYPE AS T1 JOIN TRACK AS T2 ON T1.MediaTypeId = T2.MediaTypeId WHERE T1.Name = \"AAC audio file\"",
"query_toks": [
"SELECT",
"COUNT",
"(",
"*",
")",
"FROM",
"MEDIATYPE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.MediaTypeId",
"=",
"T2.MediaTypeId",
"WHERE",
"T1.Name",
"=",
"``",
"AAC",
"audio",
"file",
"''"
],
"query_toks_no_value": [
"select",
"count",
"(",
"*",
")",
"from",
"mediatype",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"mediatypeid",
"=",
"t2",
".",
"mediatypeid",
"where",
"t1",
".",
"name",
"=",
"value"
],
"question": "Count the number of tracks that are of the media type \"AAC audio file\".",
"question_toks": [
"Count",
"the",
"number",
"of",
"tracks",
"that",
"are",
"of",
"the",
"media",
"type",
"``",
"AAC",
"audio",
"file",
"''",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
50,
false
],
null
],
[
0,
59,
false
],
null
]
],
"table_units": [
[
"table_unit",
7
],
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
3,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
51,
false
],
null
],
"\"AAC audio file\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT AVG(Milliseconds) FROM GENRE AS T1 JOIN TRACK AS T2 ON T1.GenreId = T2.GenreId WHERE T1.Name = \"Latin\" OR T1.Name = \"Pop\"",
"query_toks": [
"SELECT",
"AVG",
"(",
"Milliseconds",
")",
"FROM",
"GENRE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.GenreId",
"=",
"T2.GenreId",
"WHERE",
"T1.Name",
"=",
"``",
"Latin",
"''",
"OR",
"T1.Name",
"=",
"``",
"Pop",
"''"
],
"query_toks_no_value": [
"select",
"avg",
"(",
"milliseconds",
")",
"from",
"genre",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"genreid",
"=",
"t2",
".",
"genreid",
"where",
"t1",
".",
"name",
"=",
"value",
"or",
"t1",
".",
"name",
"=",
"value"
],
"question": "What is the average duration in milliseconds of tracks that belong to Latin or Pop genre?",
"question_toks": [
"What",
"is",
"the",
"average",
"duration",
"in",
"milliseconds",
"of",
"tracks",
"that",
"belong",
"to",
"Latin",
"or",
"Pop",
"genre",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
34,
false
],
null
],
[
0,
60,
false
],
null
]
],
"table_units": [
[
"table_unit",
4
],
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
5,
[
0,
[
0,
62,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Latin\"",
null
],
"or",
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Pop\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT AVG(Milliseconds) FROM GENRE AS T1 JOIN TRACK AS T2 ON T1.GenreId = T2.GenreId WHERE T1.Name = \"Latin\" OR T1.Name = \"Pop\"",
"query_toks": [
"SELECT",
"AVG",
"(",
"Milliseconds",
")",
"FROM",
"GENRE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.GenreId",
"=",
"T2.GenreId",
"WHERE",
"T1.Name",
"=",
"``",
"Latin",
"''",
"OR",
"T1.Name",
"=",
"``",
"Pop",
"''"
],
"query_toks_no_value": [
"select",
"avg",
"(",
"milliseconds",
")",
"from",
"genre",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"genreid",
"=",
"t2",
".",
"genreid",
"where",
"t1",
".",
"name",
"=",
"value",
"or",
"t1",
".",
"name",
"=",
"value"
],
"question": "Find the average millisecond length of Latin and Pop tracks.",
"question_toks": [
"Find",
"the",
"average",
"millisecond",
"length",
"of",
"Latin",
"and",
"Pop",
"tracks",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
34,
false
],
null
],
[
0,
60,
false
],
null
]
],
"table_units": [
[
"table_unit",
4
],
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
5,
[
0,
[
0,
62,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Latin\"",
null
],
"or",
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Pop\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT T1.FirstName , T1.SupportRepId FROM CUSTOMER AS T1 JOIN EMPLOYEE AS T2 ON T1.SupportRepId = T2.EmployeeId GROUP BY T1.SupportRepId HAVING COUNT(*) >= 10",
"query_toks": [
"SELECT",
"T1.FirstName",
",",
"T1.SupportRepId",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"EMPLOYEE",
"AS",
"T2",
"ON",
"T1.SupportRepId",
"=",
"T2.EmployeeId",
"GROUP",
"BY",
"T1.SupportRepId",
"HAVING",
"COUNT",
"(",
"*",
")",
">",
"=",
"10"
],
"query_toks_no_value": [
"select",
"t1",
".",
"firstname",
",",
"t1",
".",
"supportrepid",
"from",
"customer",
"as",
"t1",
"join",
"employee",
"as",
"t2",
"on",
"t1",
".",
"supportrepid",
"=",
"t2",
".",
"employeeid",
"group",
"by",
"t1",
".",
"supportrepid",
"having",
"count",
"(",
"*",
")",
">",
"=",
"value"
],
"question": "Please show the employee first names and ids of employees who serve at least 10 customers.",
"question_toks": [
"Please",
"show",
"the",
"employee",
"first",
"names",
"and",
"ids",
"of",
"employees",
"who",
"serve",
"at",
"least",
"10",
"customers",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
18,
false
],
null
],
[
0,
19,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
3
]
]
},
"groupBy": [
[
0,
18,
false
]
],
"having": [
[
false,
5,
[
0,
[
3,
0,
false
],
null
],
10.0,
null
]
],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
7,
false
],
null
]
],
[
0,
[
0,
[
0,
18,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT T1.FirstName , T1.SupportRepId FROM CUSTOMER AS T1 JOIN EMPLOYEE AS T2 ON T1.SupportRepId = T2.EmployeeId GROUP BY T1.SupportRepId HAVING COUNT(*) >= 10",
"query_toks": [
"SELECT",
"T1.FirstName",
",",
"T1.SupportRepId",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"EMPLOYEE",
"AS",
"T2",
"ON",
"T1.SupportRepId",
"=",
"T2.EmployeeId",
"GROUP",
"BY",
"T1.SupportRepId",
"HAVING",
"COUNT",
"(",
"*",
")",
">",
"=",
"10"
],
"query_toks_no_value": [
"select",
"t1",
".",
"firstname",
",",
"t1",
".",
"supportrepid",
"from",
"customer",
"as",
"t1",
"join",
"employee",
"as",
"t2",
"on",
"t1",
".",
"supportrepid",
"=",
"t2",
".",
"employeeid",
"group",
"by",
"t1",
".",
"supportrepid",
"having",
"count",
"(",
"*",
")",
">",
"=",
"value"
],
"question": "What are the first names and support rep ids for employees serving 10 or more customers?",
"question_toks": [
"What",
"are",
"the",
"first",
"names",
"and",
"support",
"rep",
"ids",
"for",
"employees",
"serving",
"10",
"or",
"more",
"customers",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
18,
false
],
null
],
[
0,
19,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
3
]
]
},
"groupBy": [
[
0,
18,
false
]
],
"having": [
[
false,
5,
[
0,
[
3,
0,
false
],
null
],
10.0,
null
]
],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
7,
false
],
null
]
],
[
0,
[
0,
[
0,
18,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT T1.LastName FROM CUSTOMER AS T1 JOIN EMPLOYEE AS T2 ON T1.SupportRepId = T2.EmployeeId GROUP BY T1.SupportRepId HAVING COUNT(*) <= 20",
"query_toks": [
"SELECT",
"T1.LastName",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"EMPLOYEE",
"AS",
"T2",
"ON",
"T1.SupportRepId",
"=",
"T2.EmployeeId",
"GROUP",
"BY",
"T1.SupportRepId",
"HAVING",
"COUNT",
"(",
"*",
")",
"<",
"=",
"20"
],
"query_toks_no_value": [
"select",
"t1",
".",
"lastname",
"from",
"customer",
"as",
"t1",
"join",
"employee",
"as",
"t2",
"on",
"t1",
".",
"supportrepid",
"=",
"t2",
".",
"employeeid",
"group",
"by",
"t1",
".",
"supportrepid",
"having",
"count",
"(",
"*",
")",
"<",
"=",
"value"
],
"question": "Please show the employee last names that serves no more than 20 customers.",
"question_toks": [
"Please",
"show",
"the",
"employee",
"last",
"names",
"that",
"serves",
"no",
"more",
"than",
"20",
"customers",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
18,
false
],
null
],
[
0,
19,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
3
]
]
},
"groupBy": [
[
0,
18,
false
]
],
"having": [
[
false,
6,
[
0,
[
3,
0,
false
],
null
],
20.0,
null
]
],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
8,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT T1.LastName FROM CUSTOMER AS T1 JOIN EMPLOYEE AS T2 ON T1.SupportRepId = T2.EmployeeId GROUP BY T1.SupportRepId HAVING COUNT(*) <= 20",
"query_toks": [
"SELECT",
"T1.LastName",
"FROM",
"CUSTOMER",
"AS",
"T1",
"JOIN",
"EMPLOYEE",
"AS",
"T2",
"ON",
"T1.SupportRepId",
"=",
"T2.EmployeeId",
"GROUP",
"BY",
"T1.SupportRepId",
"HAVING",
"COUNT",
"(",
"*",
")",
"<",
"=",
"20"
],
"query_toks_no_value": [
"select",
"t1",
".",
"lastname",
"from",
"customer",
"as",
"t1",
"join",
"employee",
"as",
"t2",
"on",
"t1",
".",
"supportrepid",
"=",
"t2",
".",
"employeeid",
"group",
"by",
"t1",
".",
"supportrepid",
"having",
"count",
"(",
"*",
")",
"<",
"=",
"value"
],
"question": "What are the last names of employees who serve at most 20 customers?",
"question_toks": [
"What",
"are",
"the",
"last",
"names",
"of",
"employees",
"who",
"serve",
"at",
"most",
"20",
"customers",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
18,
false
],
null
],
[
0,
19,
false
],
null
]
],
"table_units": [
[
"table_unit",
2
],
[
"table_unit",
3
]
]
},
"groupBy": [
[
0,
18,
false
]
],
"having": [
[
false,
6,
[
0,
[
3,
0,
false
],
null
],
20.0,
null
]
],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
8,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT Title FROM ALBUM ORDER BY Title",
"query_toks": [
"SELECT",
"Title",
"FROM",
"ALBUM",
"ORDER",
"BY",
"Title"
],
"query_toks_no_value": [
"select",
"title",
"from",
"album",
"order",
"by",
"title"
],
"question": "Please list all album titles in alphabetical order.",
"question_toks": [
"Please",
"list",
"all",
"album",
"titles",
"in",
"alphabetical",
"order",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
0
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [
"asc",
[
[
0,
[
0,
2,
false
],
null
]
]
],
"select": [
false,
[
[
0,
[
0,
[
0,
2,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT Title FROM ALBUM ORDER BY Title",
"query_toks": [
"SELECT",
"Title",
"FROM",
"ALBUM",
"ORDER",
"BY",
"Title"
],
"query_toks_no_value": [
"select",
"title",
"from",
"album",
"order",
"by",
"title"
],
"question": "What are all the album titles, in alphabetical order?",
"question_toks": [
"What",
"are",
"all",
"the",
"album",
"titles",
",",
"in",
"alphabetical",
"order",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
0
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [
"asc",
[
[
0,
[
0,
2,
false
],
null
]
]
],
"select": [
false,
[
[
0,
[
0,
[
0,
2,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT T2.Name , T1.ArtistId FROM ALBUM AS T1 JOIN ARTIST AS T2 ON T1.ArtistId = T2.ArtistID GROUP BY T1.ArtistId HAVING COUNT(*) >= 3 ORDER BY T2.Name",
"query_toks": [
"SELECT",
"T2.Name",
",",
"T1.ArtistId",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"ARTIST",
"AS",
"T2",
"ON",
"T1.ArtistId",
"=",
"T2.ArtistID",
"GROUP",
"BY",
"T1.ArtistId",
"HAVING",
"COUNT",
"(",
"*",
")",
">",
"=",
"3",
"ORDER",
"BY",
"T2.Name"
],
"query_toks_no_value": [
"select",
"t2",
".",
"name",
",",
"t1",
".",
"artistid",
"from",
"album",
"as",
"t1",
"join",
"artist",
"as",
"t2",
"on",
"t1",
".",
"artistid",
"=",
"t2",
".",
"artistid",
"group",
"by",
"t1",
".",
"artistid",
"having",
"count",
"(",
"*",
")",
">",
"=",
"value",
"order",
"by",
"t2",
".",
"name"
],
"question": "Please list the name and id of all artists that have at least 3 albums in alphabetical order.",
"question_toks": [
"Please",
"list",
"the",
"name",
"and",
"id",
"of",
"all",
"artists",
"that",
"have",
"at",
"least",
"3",
"albums",
"in",
"alphabetical",
"order",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
3,
false
],
null
],
[
0,
4,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
1
]
]
},
"groupBy": [
[
0,
3,
false
]
],
"having": [
[
false,
5,
[
0,
[
3,
0,
false
],
null
],
3.0,
null
]
],
"intersect": null,
"limit": null,
"orderBy": [
"asc",
[
[
0,
[
0,
5,
false
],
null
]
]
],
"select": [
false,
[
[
0,
[
0,
[
0,
5,
false
],
null
]
],
[
0,
[
0,
[
0,
3,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT T2.Name , T1.ArtistId FROM ALBUM AS T1 JOIN ARTIST AS T2 ON T1.ArtistId = T2.ArtistID GROUP BY T1.ArtistId HAVING COUNT(*) >= 3 ORDER BY T2.Name",
"query_toks": [
"SELECT",
"T2.Name",
",",
"T1.ArtistId",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"ARTIST",
"AS",
"T2",
"ON",
"T1.ArtistId",
"=",
"T2.ArtistID",
"GROUP",
"BY",
"T1.ArtistId",
"HAVING",
"COUNT",
"(",
"*",
")",
">",
"=",
"3",
"ORDER",
"BY",
"T2.Name"
],
"query_toks_no_value": [
"select",
"t2",
".",
"name",
",",
"t1",
".",
"artistid",
"from",
"album",
"as",
"t1",
"join",
"artist",
"as",
"t2",
"on",
"t1",
".",
"artistid",
"=",
"t2",
".",
"artistid",
"group",
"by",
"t1",
".",
"artistid",
"having",
"count",
"(",
"*",
")",
">",
"=",
"value",
"order",
"by",
"t2",
".",
"name"
],
"question": "What are the names and ids of artists with 3 or more albums, listed in alphabetical order?",
"question_toks": [
"What",
"are",
"the",
"names",
"and",
"ids",
"of",
"artists",
"with",
"3",
"or",
"more",
"albums",
",",
"listed",
"in",
"alphabetical",
"order",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
3,
false
],
null
],
[
0,
4,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
1
]
]
},
"groupBy": [
[
0,
3,
false
]
],
"having": [
[
false,
5,
[
0,
[
3,
0,
false
],
null
],
3.0,
null
]
],
"intersect": null,
"limit": null,
"orderBy": [
"asc",
[
[
0,
[
0,
5,
false
],
null
]
]
],
"select": [
false,
[
[
0,
[
0,
[
0,
5,
false
],
null
]
],
[
0,
[
0,
[
0,
3,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT Name FROM ARTIST EXCEPT SELECT T2.Name FROM ALBUM AS T1 JOIN ARTIST AS T2 ON T1.ArtistId = T2.ArtistId",
"query_toks": [
"SELECT",
"Name",
"FROM",
"ARTIST",
"EXCEPT",
"SELECT",
"T2.Name",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"ARTIST",
"AS",
"T2",
"ON",
"T1.ArtistId",
"=",
"T2.ArtistId"
],
"query_toks_no_value": [
"select",
"name",
"from",
"artist",
"except",
"select",
"t2",
".",
"name",
"from",
"album",
"as",
"t1",
"join",
"artist",
"as",
"t2",
"on",
"t1",
".",
"artistid",
"=",
"t2",
".",
"artistid"
],
"question": "Find the names of artists that do not have any albums.",
"question_toks": [
"Find",
"the",
"names",
"of",
"artists",
"that",
"do",
"not",
"have",
"any",
"albums",
"."
],
"sql": {
"except": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
3,
false
],
null
],
[
0,
4,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
1
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
5,
false
],
null
]
]
]
],
"union": null,
"where": []
},
"from": {
"conds": [],
"table_units": [
[
"table_unit",
1
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
5,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT Name FROM ARTIST EXCEPT SELECT T2.Name FROM ALBUM AS T1 JOIN ARTIST AS T2 ON T1.ArtistId = T2.ArtistId",
"query_toks": [
"SELECT",
"Name",
"FROM",
"ARTIST",
"EXCEPT",
"SELECT",
"T2.Name",
"FROM",
"ALBUM",
"AS",
"T1",
"JOIN",
"ARTIST",
"AS",
"T2",
"ON",
"T1.ArtistId",
"=",
"T2.ArtistId"
],
"query_toks_no_value": [
"select",
"name",
"from",
"artist",
"except",
"select",
"t2",
".",
"name",
"from",
"album",
"as",
"t1",
"join",
"artist",
"as",
"t2",
"on",
"t1",
".",
"artistid",
"=",
"t2",
".",
"artistid"
],
"question": "What are the names of artists who have not released any albums?",
"question_toks": [
"What",
"are",
"the",
"names",
"of",
"artists",
"who",
"have",
"not",
"released",
"any",
"albums",
"?"
],
"sql": {
"except": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
3,
false
],
null
],
[
0,
4,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
1
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
5,
false
],
null
]
]
]
],
"union": null,
"where": []
},
"from": {
"conds": [],
"table_units": [
[
"table_unit",
1
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
5,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT AVG(T2.UnitPrice) FROM GENRE AS T1 JOIN TRACK AS T2 ON T1.GenreId = T2.GenreId WHERE T1.Name = \"Rock\"",
"query_toks": [
"SELECT",
"AVG",
"(",
"T2.UnitPrice",
")",
"FROM",
"GENRE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.GenreId",
"=",
"T2.GenreId",
"WHERE",
"T1.Name",
"=",
"``",
"Rock",
"''"
],
"query_toks_no_value": [
"select",
"avg",
"(",
"t2",
".",
"unitprice",
")",
"from",
"genre",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"genreid",
"=",
"t2",
".",
"genreid",
"where",
"t1",
".",
"name",
"=",
"value"
],
"question": "What is the average unit price of rock tracks?",
"question_toks": [
"What",
"is",
"the",
"average",
"unit",
"price",
"of",
"rock",
"tracks",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
34,
false
],
null
],
[
0,
60,
false
],
null
]
],
"table_units": [
[
"table_unit",
4
],
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
5,
[
0,
[
0,
64,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Rock\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT AVG(T2.UnitPrice) FROM GENRE AS T1 JOIN TRACK AS T2 ON T1.GenreId = T2.GenreId WHERE T1.Name = \"Rock\"",
"query_toks": [
"SELECT",
"AVG",
"(",
"T2.UnitPrice",
")",
"FROM",
"GENRE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.GenreId",
"=",
"T2.GenreId",
"WHERE",
"T1.Name",
"=",
"``",
"Rock",
"''"
],
"query_toks_no_value": [
"select",
"avg",
"(",
"t2",
".",
"unitprice",
")",
"from",
"genre",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"genreid",
"=",
"t2",
".",
"genreid",
"where",
"t1",
".",
"name",
"=",
"value"
],
"question": "Find the average unit price of tracks from the Rock genre.",
"question_toks": [
"Find",
"the",
"average",
"unit",
"price",
"of",
"tracks",
"from",
"the",
"Rock",
"genre",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
34,
false
],
null
],
[
0,
60,
false
],
null
]
],
"table_units": [
[
"table_unit",
4
],
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
5,
[
0,
[
0,
64,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Rock\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT max(Milliseconds) , min(Milliseconds) FROM GENRE AS T1 JOIN TRACK AS T2 ON T1.GenreId = T2.GenreId WHERE T1.Name = \"Pop\"",
"query_toks": [
"SELECT",
"max",
"(",
"Milliseconds",
")",
",",
"min",
"(",
"Milliseconds",
")",
"FROM",
"GENRE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.GenreId",
"=",
"T2.GenreId",
"WHERE",
"T1.Name",
"=",
"``",
"Pop",
"''"
],
"query_toks_no_value": [
"select",
"max",
"(",
"milliseconds",
")",
",",
"min",
"(",
"milliseconds",
")",
"from",
"genre",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"genreid",
"=",
"t2",
".",
"genreid",
"where",
"t1",
".",
"name",
"=",
"value"
],
"question": "What are the duration of the longest and shortest pop tracks in milliseconds?",
"question_toks": [
"What",
"are",
"the",
"duration",
"of",
"the",
"longest",
"and",
"shortest",
"pop",
"tracks",
"in",
"milliseconds",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
34,
false
],
null
],
[
0,
60,
false
],
null
]
],
"table_units": [
[
"table_unit",
4
],
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
1,
[
0,
[
0,
62,
false
],
null
]
],
[
2,
[
0,
[
0,
62,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Pop\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT max(Milliseconds) , min(Milliseconds) FROM GENRE AS T1 JOIN TRACK AS T2 ON T1.GenreId = T2.GenreId WHERE T1.Name = \"Pop\"",
"query_toks": [
"SELECT",
"max",
"(",
"Milliseconds",
")",
",",
"min",
"(",
"Milliseconds",
")",
"FROM",
"GENRE",
"AS",
"T1",
"JOIN",
"TRACK",
"AS",
"T2",
"ON",
"T1.GenreId",
"=",
"T2.GenreId",
"WHERE",
"T1.Name",
"=",
"``",
"Pop",
"''"
],
"query_toks_no_value": [
"select",
"max",
"(",
"milliseconds",
")",
",",
"min",
"(",
"milliseconds",
")",
"from",
"genre",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"genreid",
"=",
"t2",
".",
"genreid",
"where",
"t1",
".",
"name",
"=",
"value"
],
"question": "Find the maximum and minimum millisecond lengths of pop tracks.",
"question_toks": [
"Find",
"the",
"maximum",
"and",
"minimum",
"millisecond",
"lengths",
"of",
"pop",
"tracks",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
34,
false
],
null
],
[
0,
60,
false
],
null
]
],
"table_units": [
[
"table_unit",
4
],
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
1,
[
0,
[
0,
62,
false
],
null
]
],
[
2,
[
0,
[
0,
62,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Pop\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT BirthDate FROM EMPLOYEE WHERE City = \"Edmonton\"",
"query_toks": [
"SELECT",
"BirthDate",
"FROM",
"EMPLOYEE",
"WHERE",
"City",
"=",
"``",
"Edmonton",
"''"
],
"query_toks_no_value": [
"select",
"birthdate",
"from",
"employee",
"where",
"city",
"=",
"value"
],
"question": "What are the birth dates of employees living in Edmonton?",
"question_toks": [
"What",
"are",
"the",
"birth",
"dates",
"of",
"employees",
"living",
"in",
"Edmonton",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
3
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
24,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
27,
false
],
null
],
"\"Edmonton\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT BirthDate FROM EMPLOYEE WHERE City = \"Edmonton\"",
"query_toks": [
"SELECT",
"BirthDate",
"FROM",
"EMPLOYEE",
"WHERE",
"City",
"=",
"``",
"Edmonton",
"''"
],
"query_toks_no_value": [
"select",
"birthdate",
"from",
"employee",
"where",
"city",
"=",
"value"
],
"question": "Find the birth dates corresponding to employees who live in the city of Edmonton.",
"question_toks": [
"Find",
"the",
"birth",
"dates",
"corresponding",
"to",
"employees",
"who",
"live",
"in",
"the",
"city",
"of",
"Edmonton",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
3
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
24,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
27,
false
],
null
],
"\"Edmonton\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT distinct(UnitPrice) FROM TRACK",
"query_toks": [
"SELECT",
"distinct",
"(",
"UnitPrice",
")",
"FROM",
"TRACK"
],
"query_toks_no_value": [
"select",
"distinct",
"(",
"unitprice",
")",
"from",
"track"
],
"question": "What are the distinct unit prices of all tracks?",
"question_toks": [
"What",
"are",
"the",
"distinct",
"unit",
"prices",
"of",
"all",
"tracks",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
true,
[
[
0,
[
0,
[
0,
64,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT distinct(UnitPrice) FROM TRACK",
"query_toks": [
"SELECT",
"distinct",
"(",
"UnitPrice",
")",
"FROM",
"TRACK"
],
"query_toks_no_value": [
"select",
"distinct",
"(",
"unitprice",
")",
"from",
"track"
],
"question": "Find the distinct unit prices for tracks.",
"question_toks": [
"Find",
"the",
"distinct",
"unit",
"prices",
"for",
"tracks",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
10
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
true,
[
[
0,
[
0,
[
0,
64,
false
],
null
]
]
]
],
"union": null,
"where": []
}
},
{
"db_id": "chinook_1",
"query": "SELECT count(*) FROM ARTIST WHERE artistid NOT IN(SELECT artistid FROM ALBUM)",
"query_toks": [
"SELECT",
"count",
"(",
"*",
")",
"FROM",
"ARTIST",
"WHERE",
"artistid",
"NOT",
"IN",
"(",
"SELECT",
"artistid",
"FROM",
"ALBUM",
")"
],
"query_toks_no_value": [
"select",
"count",
"(",
"*",
")",
"from",
"artist",
"where",
"artistid",
"not",
"in",
"(",
"select",
"artistid",
"from",
"album",
")"
],
"question": "How many artists do not have any album?",
"question_toks": [
"How",
"many",
"artists",
"do",
"not",
"have",
"any",
"album",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
1
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
3,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": [
[
true,
8,
[
0,
[
0,
4,
false
],
null
],
{
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
0
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
3,
false
],
null
]
]
]
],
"union": null,
"where": []
},
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT count(*) FROM ARTIST WHERE artistid NOT IN(SELECT artistid FROM ALBUM)",
"query_toks": [
"SELECT",
"count",
"(",
"*",
")",
"FROM",
"ARTIST",
"WHERE",
"artistid",
"NOT",
"IN",
"(",
"SELECT",
"artistid",
"FROM",
"ALBUM",
")"
],
"query_toks_no_value": [
"select",
"count",
"(",
"*",
")",
"from",
"artist",
"where",
"artistid",
"not",
"in",
"(",
"select",
"artistid",
"from",
"album",
")"
],
"question": "Cound the number of artists who have not released an album.",
"question_toks": [
"Cound",
"the",
"number",
"of",
"artists",
"who",
"have",
"not",
"released",
"an",
"album",
"."
],
"sql": {
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
1
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
3,
[
0,
[
0,
0,
false
],
null
]
]
]
],
"union": null,
"where": [
[
true,
8,
[
0,
[
0,
4,
false
],
null
],
{
"except": null,
"from": {
"conds": [],
"table_units": [
[
"table_unit",
0
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
3,
false
],
null
]
]
]
],
"union": null,
"where": []
},
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT T1.Title FROM Album AS T1 JOIN Track AS T2 ON T1.AlbumId = T2.AlbumId JOIN Genre AS T3 ON T2.GenreID = T3.GenreID WHERE T3.Name = 'Reggae' INTERSECT SELECT T1.Title FROM Album AS T1 JOIN Track AS T2 ON T1.AlbumId = T2.AlbumId JOIN Genre AS T3 ON T2.GenreID = T3.GenreID WHERE T3.Name = 'Rock'",
"query_toks": [
"SELECT",
"T1.Title",
"FROM",
"Album",
"AS",
"T1",
"JOIN",
"Track",
"AS",
"T2",
"ON",
"T1.AlbumId",
"=",
"T2.AlbumId",
"JOIN",
"Genre",
"AS",
"T3",
"ON",
"T2.GenreID",
"=",
"T3.GenreID",
"WHERE",
"T3.Name",
"=",
"'Reggae",
"'",
"INTERSECT",
"SELECT",
"T1.Title",
"FROM",
"Album",
"AS",
"T1",
"JOIN",
"Track",
"AS",
"T2",
"ON",
"T1.AlbumId",
"=",
"T2.AlbumId",
"JOIN",
"Genre",
"AS",
"T3",
"ON",
"T2.GenreID",
"=",
"T3.GenreID",
"WHERE",
"T3.Name",
"=",
"'Rock",
"'"
],
"query_toks_no_value": [
"select",
"t1",
".",
"title",
"from",
"album",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"albumid",
"=",
"t2",
".",
"albumid",
"join",
"genre",
"as",
"t3",
"on",
"t2",
".",
"genreid",
"=",
"t3",
".",
"genreid",
"where",
"t3",
".",
"name",
"=",
"value",
"intersect",
"select",
"t1",
".",
"title",
"from",
"album",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"albumid",
"=",
"t2",
".",
"albumid",
"join",
"genre",
"as",
"t3",
"on",
"t2",
".",
"genreid",
"=",
"t3",
".",
"genreid",
"where",
"t3",
".",
"name",
"=",
"value"
],
"question": "What are the album titles for albums containing both 'Reggae' and 'Rock' genre tracks?",
"question_toks": [
"What",
"are",
"the",
"album",
"titles",
"for",
"albums",
"containing",
"both",
"'Reggae",
"'",
"and",
"'Rock",
"'",
"genre",
"tracks",
"?"
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
1,
false
],
null
],
[
0,
58,
false
],
null
],
"and",
[
false,
2,
[
0,
[
0,
60,
false
],
null
],
[
0,
34,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
10
],
[
"table_unit",
4
]
]
},
"groupBy": [],
"having": [],
"intersect": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
1,
false
],
null
],
[
0,
58,
false
],
null
],
"and",
[
false,
2,
[
0,
[
0,
60,
false
],
null
],
[
0,
34,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
10
],
[
"table_unit",
4
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
2,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Rock\"",
null
]
]
},
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
2,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Reggae\"",
null
]
]
}
},
{
"db_id": "chinook_1",
"query": "SELECT T1.Title FROM Album AS T1 JOIN Track AS T2 ON T1.AlbumId = T2.AlbumId JOIN Genre AS T3 ON T2.GenreID = T3.GenreID WHERE T3.Name = 'Reggae' INTERSECT SELECT T1.Title FROM Album AS T1 JOIN Track AS T2 ON T1.AlbumId = T2.AlbumId JOIN Genre AS T3 ON T2.GenreID = T3.GenreID WHERE T3.Name = 'Rock'",
"query_toks": [
"SELECT",
"T1.Title",
"FROM",
"Album",
"AS",
"T1",
"JOIN",
"Track",
"AS",
"T2",
"ON",
"T1.AlbumId",
"=",
"T2.AlbumId",
"JOIN",
"Genre",
"AS",
"T3",
"ON",
"T2.GenreID",
"=",
"T3.GenreID",
"WHERE",
"T3.Name",
"=",
"'Reggae",
"'",
"INTERSECT",
"SELECT",
"T1.Title",
"FROM",
"Album",
"AS",
"T1",
"JOIN",
"Track",
"AS",
"T2",
"ON",
"T1.AlbumId",
"=",
"T2.AlbumId",
"JOIN",
"Genre",
"AS",
"T3",
"ON",
"T2.GenreID",
"=",
"T3.GenreID",
"WHERE",
"T3.Name",
"=",
"'Rock",
"'"
],
"query_toks_no_value": [
"select",
"t1",
".",
"title",
"from",
"album",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"albumid",
"=",
"t2",
".",
"albumid",
"join",
"genre",
"as",
"t3",
"on",
"t2",
".",
"genreid",
"=",
"t3",
".",
"genreid",
"where",
"t3",
".",
"name",
"=",
"value",
"intersect",
"select",
"t1",
".",
"title",
"from",
"album",
"as",
"t1",
"join",
"track",
"as",
"t2",
"on",
"t1",
".",
"albumid",
"=",
"t2",
".",
"albumid",
"join",
"genre",
"as",
"t3",
"on",
"t2",
".",
"genreid",
"=",
"t3",
".",
"genreid",
"where",
"t3",
".",
"name",
"=",
"value"
],
"question": "Find the titles of albums that contain tracks of both the Reggae and Rock genres.",
"question_toks": [
"Find",
"the",
"titles",
"of",
"albums",
"that",
"contain",
"tracks",
"of",
"both",
"the",
"Reggae",
"and",
"Rock",
"genres",
"."
],
"sql": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
1,
false
],
null
],
[
0,
58,
false
],
null
],
"and",
[
false,
2,
[
0,
[
0,
60,
false
],
null
],
[
0,
34,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
10
],
[
"table_unit",
4
]
]
},
"groupBy": [],
"having": [],
"intersect": {
"except": null,
"from": {
"conds": [
[
false,
2,
[
0,
[
0,
1,
false
],
null
],
[
0,
58,
false
],
null
],
"and",
[
false,
2,
[
0,
[
0,
60,
false
],
null
],
[
0,
34,
false
],
null
]
],
"table_units": [
[
"table_unit",
0
],
[
"table_unit",
10
],
[
"table_unit",
4
]
]
},
"groupBy": [],
"having": [],
"intersect": null,
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
2,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Rock\"",
null
]
]
},
"limit": null,
"orderBy": [],
"select": [
false,
[
[
0,
[
0,
[
0,
2,
false
],
null
]
]
]
],
"union": null,
"where": [
[
false,
2,
[
0,
[
0,
35,
false
],
null
],
"\"Reggae\"",
null
]
]
}
}
]