Chinastark/bird_dataset huggingface dataset:
Database: menu
Question: Which dish has the highest price on the menu "Zentral Theater Terrace"? Please give its name.
Evidence: highest price refers to MAX(Price); Zentral Theater Terrace is a name of menu;
SQL: SELECT T4.name FROM MenuItem AS T1 INNER JOIN MenuPage AS T2 ON T1.menu_page_id = T2.id INNER JOIN Menu AS T3 ON T2.menu_id = T3.id INNER JOIN Dish AS T4 ON T1.dish_id = T4.id WHERE T3.name = 'Zentral Theater Terrace' ORDER BY T1.price DESC LIMIT 1
Database: menu
Question: How many dishes are there on the menu "Zentral Theater Terrace"?
Evidence: Zentral Theater Terrace is a name of menu;
SQL: SELECT SUM(CASE WHEN T3.name = 'Zentral Theater Terrace' THEN 1 ELSE 0 END) FROM MenuItem AS T1 INNER JOIN MenuPage AS T2 ON T1.menu_page_id = T2.id INNER JOIN Menu AS T3 ON T2.menu_id = T3.id
Database: menu
Question: How many dishes are there in total in the menus with the name "Waldorf Astoria"?
Evidence: FALSE;
SQL: SELECT SUM(CASE WHEN T3.name = 'Waldorf Astoria' THEN 1 ELSE 0 END) FROM MenuItem AS T1 INNER JOIN MenuPage AS T2 ON T1.menu_page_id = T2.id INNER JOIN Menu AS T3 ON T2.menu_id = T3.id
Database: menu
Question: Please list the IDs of the menus that are DIYs of the restaurant and have the dish "Clear green turtle".
Evidence: IDs of the menus refers to menu_id; menus that are DIYs of the restaurant refers to sponsor is null; Clear green turtle is a name of dish;
SQL: SELECT T2.menu_id FROM MenuItem AS T1 INNER JOIN MenuPage AS T2 ON T1.menu_page_id = T2.id INNER JOIN Menu AS T3 ON T2.menu_id = T3.id INNER JOIN Dish AS T4 ON T1.dish_id = T4.id WHERE T4.name = 'Clear green turtle' AND T3.sponsor IS NULL
Database: menu
Question: What is the average page number of the menus that have the dish "Clear green turtle"?
Evidence: average page number = AVG(page_number); Clear green turtle is a name of dish;
SQL: SELECT AVG(T1.page_number) FROM MenuPage AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.menu_page_id INNER JOIN Dish AS T3 ON T2.dish_id = T3.id WHERE T3.name = 'Clear green turtle'
Database: menu
Question: What is the average price of the dishes on the menu "Zentral Theater Terrace"?
Evidence: average price = AVG(price); Zentral Theater Terrace refers to menu;
SQL: SELECT SUM(T1.price) / COUNT(T1.price) FROM MenuItem AS T1 INNER JOIN MenuPage AS T2 ON T1.menu_page_id = T2.id INNER JOIN Menu AS T3 ON T2.menu_id = T3.id WHERE T3.name = 'Zentral Theater Terrace'
Database: menu
Question: How many menu items were created on 28th March 2011?
Evidence: created on 28th March 2011 refers to created_at like '2011-03-28%';
SQL: SELECT COUNT(*) FROM MenuItem WHERE created_at LIKE '2011-03-28%'
Database: menu
Question: How many dishes are included in the menu page ID 144?
Evidence: FALSE;
SQL: SELECT COUNT(*) FROM MenuItem WHERE menu_page_id = 144
Database: menu
Question: How many menus were used in Dutcher House?
Evidence: Dutcher House refers to location = 'Dutcher House';
SQL: SELECT COUNT(*) FROM Menu WHERE location = 'Dutcher House'
Database: menu
Question: How many dishes appeared on a menu more than once?
Evidence: appeared on a menu more than once refers to times_appeared > menus_appeared;
SQL: SELECT COUNT(*) FROM Dish WHERE times_appeared > menus_appeared
Database: menu
Question: How many menus were created for steamship?
Evidence: steamship refers to venue = 'STEAMSHIP';
SQL: SELECT COUNT(*) FROM Menu WHERE venue = 'STEAMSHIP'
Database: menu
Question: How many pages were there on the menu created on 17th November 1898?
Evidence: created on 17th November 1898 refers to date = '1898-11-17';
SQL: SELECT SUM(CASE WHEN T1.date = '1898-11-17' THEN 1 ELSE 0 END) FROM Menu AS T1 INNER JOIN MenuPage AS T2 ON T1.id = T2.menu_id
Database: menu
Question: Name the dishes that were on the menu page ID 174.
Evidence: FALSE;
SQL: SELECT T2.name FROM MenuItem AS T1 INNER JOIN Dish AS T2 ON T2.id = T1.dish_id WHERE T1.menu_page_id = 174
Database: menu
Question: List the names and menu page IDs of the dishes that first appeared in 1861.
Evidence: first appeared in 1861 refers to first_appeared = 1861;
SQL: SELECT T2.name, T1.dish_id FROM MenuItem AS T1 INNER JOIN Dish AS T2 ON T2.id = T1.dish_id WHERE T2.first_appeared = 1861
Database: menu
Question: Among the dishes on menu page ID 7610, list the names and highest prices of the dishes in menu items that were created on 23rd May 2011.
Evidence: highest prices of the dishes refers to MAX(price); created on 23rd May 2011 refers to created_at like '2011-05-23%';
SQL: SELECT T1.name, T2.price FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id WHERE T2.created_at LIKE '2011-05-23%' ORDER BY T2.price DESC LIMIT 1
Database: menu
Question: List the dishes included on page number 30 with the least in full height.
Evidence: least in full height refers to MIN(full_height);
SQL: SELECT T3.name FROM MenuPage AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.menu_page_id INNER JOIN Dish AS T3 ON T2.dish_id = T3.id WHERE T1.page_number = 30 ORDER BY T1.full_height DESC, T1.full_height ASC LIMIT 1
Database: menu
Question: Provide the page IDs and name of the menu which had the highest page count.
Evidence: page IDs refers to page_number; highest page count refers to MAX(page_count);
SQL: SELECT T1.page_number, T2.name FROM MenuPage AS T1 INNER JOIN Menu AS T2 ON T2.id = T1.menu_id ORDER BY T2.page_count DESC LIMIT 1
Database: menu
Question: On the menu with the most dishes, how many dishes were there on its second page?
Evidence: menu with the most dishes refers to menu.id with MAX(dish_count); second page refers to page_number = 2;
SQL: SELECT COUNT(T1.dish_id) FROM MenuItem AS T1 INNER JOIN MenuPage AS T2 ON T1.menu_page_id = T2.id INNER JOIN Menu AS T3 ON T2.menu_id = T3.id WHERE T2.page_number = 2 GROUP BY T3.name ORDER BY T3.dish_count DESC LIMIT 1
Database: menu
Question: Provide the numbers of the menu item which includes Fresh lobsters in every style and location where that dish was used on a menu.
Evidence: Fresh lobsters in every style' is a name of dish; location where the dish was used on a menu = (xpos, ypos);
SQL: SELECT T2.menu_id, T1.xpos, T1.ypos FROM MenuItem AS T1 INNER JOIN MenuPage AS T2 ON T1.menu_page_id = T2.id INNER JOIN Menu AS T3 ON T2.menu_id = T3.id INNER JOIN Dish AS T4 ON T1.dish_id = T4.id WHERE T4.name = 'Fresh lobsters in every style'
Database: menu
Question: List the dishes that appeared at the left upper corner of the CHAS.BRADLEY'S OYSTER & DINING ROOM"s sponsored menu.
Evidence: appeared at the left upper corner refers to xpos < 0.25 and ypos < 0.25; CHAS.BRADLEY'S OYSTER & DINING ROOM refers to sponsor = 'CHAS.BRADLEY''S OYSTER & DINING ROOM';
SQL: SELECT T4.name FROM MenuItem AS T1 INNER JOIN MenuPage AS T2 ON T1.menu_page_id = T2.id INNER JOIN Menu AS T3 ON T2.menu_id = T3.id INNER JOIN Dish AS T4 ON T1.dish_id = T4.id WHERE T3.sponsor = 'CHAS.BRADLEY''S OYSTER & DINING ROOM' AND T1.xpos < 0.25 AND T1.ypos < 0.25
Database: menu
Question: Provide the sponsor and event of the menu which includes Cerealine with Milk.
Evidence: Cerealine with Milk is a name of dish;
SQL: SELECT T3.name, T3.event FROM MenuItem AS T1 INNER JOIN MenuPage AS T2 ON T1.menu_page_id = T2.id INNER JOIN Menu AS T3 ON T2.menu_id = T3.id INNER JOIN Dish AS T4 ON T1.dish_id = T4.id WHERE T4.name = 'Cerealine with Milk'
Database: menu
Question: How many percent of Bluefish dishes are located at the center of the menu page?
Evidence: percent = MULTIPLY(DIVIDE(SUM(xpos BETWEEN 0.25 AND 0.75 and ypos BETWEEN 0.25 AND 0.75), COUNT(id)), 1.0); Bluefish is a sub name of dish; located at the center of the menu page refers to xpos BETWEEN 0.25 AND 0.75 and ypos BETWEEN 0.25 AND 0.75;
SQL: SELECT CAST(SUM(CASE WHEN T2.xpos BETWEEN 0.25 AND 0.75 AND T2.ypos BETWEEN 0.25 AND 0.75 THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(T2.id) FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id WHERE T1.name LIKE '%BLuefish%'
Database: menu
Question: Who is the sponsor of menu with ID 12463?
Evidence: FALSE;
SQL: SELECT sponsor FROM Menu WHERE id = 12463
Database: menu
Question: What is the event sponsored by the Republican House?
Evidence: sponsored by the Republican House refers to sponsor = 'REPUBLICAN HOUSE';
SQL: SELECT event FROM Menu WHERE sponsor = 'REPUBLICAN HOUSE'
Database: menu
Question: Where is the place that menu with ID 12472 was created for?
Evidence: place refers to location;
SQL: SELECT location FROM Menu WHERE id = 12472
Database: menu
Question: Please describe the menu sponsored by Noviomagus physically.
Evidence: describe the menu physically refers to physical_description; sponsored by Noviomagus refers to sponsor = 'Noviomagus';
SQL: SELECT physical_description FROM Menu WHERE sponsor = 'Noviomagus'
Database: menu
Question: What is the occasion for menu with ID 12463?
Evidence: FALSE;
SQL: SELECT occasion FROM Menu WHERE id = 12463
Database: menu
Question: List down the locations of menu sponsored by Norddeutscher Lloyd Bremen.
Evidence: sponsored by Norddeutscher Lloyd Bremen refers to sponsor = 'Norddeutscher Lloyd Bremen';
SQL: SELECT location FROM Menu WHERE sponsor = 'Norddeutscher Lloyd Bremen'
Database: menu
Question: List down the menu page IDs for menu sponsored by Occidental & Oriental?
Evidence: menu page IDs refers to MenuPage.id; sponsored by Occidental & Oriental refers to sponsor = 'Occidental & Oriental';
SQL: SELECT T2.id FROM MenuPage AS T1 INNER JOIN Menu AS T2 ON T2.id = T1.menu_id WHERE T2.sponsor = 'Occidental & Oriental'
Database: menu
Question: List down the image IDs for menu located at Manhattan Hotel.
Evidence: located at Manhattan Hotel refers to location = 'Manhattan Hotel';
SQL: SELECT T1.image_id FROM MenuPage AS T1 INNER JOIN Menu AS T2 ON T2.id = T1.menu_id WHERE T2.location = 'Manhattan Hotel'
Database: menu
Question: State the full height and width for menu called "El Fuerte Del Palmar".
Evidence: width refers to full_width; El Fuerte Del Palmar is a name of menu;
SQL: SELECT T1.full_height, T1.full_width FROM MenuPage AS T1 INNER JOIN Menu AS T2 ON T2.id = T1.menu_id WHERE T2.name = 'El Fuerte Del Palmar'
Database: menu
Question: Is "c02c9a3b-6881-7080-e040-e00a180631aa" the uuid for menu called "The Biltmore"?
Evidence: if 'c02c9a3b-6881-7080-e040-e00a180631aa' can be found in uuid, it means the 'c02c9a3b-6881-7080-e040-e00a180631aa' is the uuid for the menu called The Biltmore; if 'c02c9a3b-6881-7080-e040-e00a180631aa' can not be found in uuid, it means the 'c02c9a3b-6881-7080-e040-e00a180631aa' is not the uuid for the menu called The Biltmore; The Biltmore is a name of menu;
SQL: SELECT CASE WHEN T2.uuid = 'c02c9a3b-6881-7080-e040-e00a180631aa' THEN 'yes' ELSE 'no' END AS yn FROM Menu AS T1 INNER JOIN MenuPage AS T2 ON T1.id = T2.menu_id WHERE T1.name = 'The Biltmore' AND T2.uuid = 'c02c9a3b-6881-7080-e040-e00a180631aa'
Database: menu
Question: State the name of menu with the longest full height.
Evidence: longest full height refers to MAX(full_height);
SQL: SELECT T2.name FROM MenuPage AS T1 INNER JOIN Menu AS T2 ON T2.id = T1.menu_id ORDER BY T1.full_height DESC LIMIT 1
Database: menu
Question: What is the page count for menu with page ID of 130?
Evidence: page ID of 130 refers MenuPage.id = 130;
SQL: SELECT T1.page_count FROM Menu AS T1 INNER JOIN MenuPage AS T2 ON T1.id = T2.menu_id WHERE T2.id = 130
Database: menu
Question: How much is the price of menu with image ID 4000009194?
Evidence: FALSE;
SQL: SELECT T3.price FROM Menu AS T1 INNER JOIN MenuPage AS T2 ON T1.id = T2.menu_id INNER JOIN MenuItem AS T3 ON T2.id = T3.menu_page_id WHERE T2.image_id = 4000009194
Database: menu
Question: List down the page numbers for menu with dishes on the right upper corner.
Evidence: on the right upper corner refers to xpos > 0.75 AND ypos < 0.25;
SQL: SELECT T2.page_number FROM Menu AS T1 INNER JOIN MenuPage AS T2 ON T1.id = T2.menu_id INNER JOIN MenuItem AS T3 ON T2.id = T3.menu_page_id WHERE T3.xpos > 0.75 AND T3.ypos < 0.25
Database: menu
Question: List down the name of dishes from menu created in April.
Evidence: created in April refers to SUBSTR(created_at, 7, 1) = '4';
SQL: SELECT T2.name FROM MenuItem AS T1 INNER JOIN Dish AS T2 ON T2.id = T1.dish_id WHERE SUBSTR(T1.created_at, 7, 1) = '4'
Database: menu
Question: List down name of dishes from menu with menu page ID 1389.
Evidence: FALSE;
SQL: SELECT T2.name FROM MenuItem AS T1 INNER JOIN Dish AS T2 ON T2.id = T1.dish_id WHERE T1.menu_page_id = 1389
Database: menu
Question: What is the highest price of dishes with menu item ID 1 to 5?
Evidence: highest price refers to MAX(price); menu item ID 1 to 5 refers to MenuItem.id BETWEEN 1 AND 5;
SQL: SELECT T2.price FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id WHERE T2.id BETWEEN 1 AND 5 ORDER BY T2.price DESC LIMIT 1
Database: menu
Question: List down the name of dishes that were positioned on the left upper corner.
Evidence: positioned on the left upper corner refers to xpos < 0.25 AND ypos < 0.25;
SQL: SELECT T1.name FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id WHERE T2.xpos < 0.25 AND T2.ypos < 0.25
Database: menu
Question: Calculate the total dish count for menu with uuid of "510d47e4-2958-a3d9-e040-e00a18064a99" & "510d47e4-295a-a3d9-e040-e00a18064a99".
Evidence: total dish count for uuid of '510d47e4-2958-a3d9-e040-e00a18064a99' = SUM(dish_count WHERE uuid = '510d47e4-2958-a3d9-e040-e00a18064a99'); total dish count for uuid of '510d47e4-295a-a3d9-e040-e00a18064a99 = SUM(dish_count WHERE uuid = '510d47e4-295a-a3d9-e040-e00a18064a99');
SQL: SELECT SUM(CASE WHEN T2.uuid = '510d47e4-2958-a3d9-e040-e00a18064a99' THEN T1.dish_count ELSE 0 END) - SUM(CASE WHEN T2.uuid = '510d47e4-295a-a3d9-e040-e00a18064a99' THEN T1.dish_count ELSE 0 END) FROM Menu AS T1 INNER JOIN MenuPage AS T2 ON T1.id = T2.menu_id
Database: menu
Question: Calculate the total price of items for menu with ID 12882.
Evidence: total price = SUM(price);
SQL: SELECT SUM(T2.price) FROM MenuPage AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.menu_page_id WHERE T1.menu_id = 12882
Database: menu
Question: List the top five dishes, by descending order, in terms of highest price.
Evidence: highest price refers to MAX(highest_price);
SQL: SELECT name FROM Dish ORDER BY highest_price DESC LIMIT 5
Database: menu
Question: Among the dishes, how many of them are for free?
Evidence: free refers to lowest_price = 0;
SQL: SELECT COUNT(*) FROM Dish WHERE lowest_price = 0
Database: menu
Question: What dishes made their first and last appearances in 1855 and 1900, respectively?
Evidence: first appearance in 1855 refers to first_appeared = 1855; last appearance in 1900 refers to last_appeared = 1900;
SQL: SELECT name FROM Dish WHERE first_appeared = 1855 AND last_appeared = 1900
Database: menu
Question: Write down the top ten menus with the highest dish count.
Evidence: highest dish count refers to MAX(dish_count);
SQL: SELECT name FROM Menu GROUP BY name ORDER BY dish_count DESC LIMIT 10
Database: menu
Question: How many dishes appear in the right upper corner of the menu page?
Evidence: appear in the right upper corner of the menu page refers to xpos > 0.75 and ypos < 0.25;
SQL: SELECT COUNT(*) FROM MenuItem AS T1 INNER JOIN Dish AS T2 ON T1.dish_id = T2.id WHERE T1.xpos > 0.75 AND T1.ypos < 0.25
Database: menu
Question: How long has the "Clear Green Turtle" dish appeared on the menu, and tell me when its latest update was?
Evidence: Clear Green Turtle is a name of dish; how long a dish appeared on the menu = SUBTRACT(last_appeared, first_appeared); latest update refers to latest updated_at;
SQL: SELECT T1.last_appeared - T1.first_appeared, T2.updated_at FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id WHERE T1.name = 'Clear green turtle'
Database: menu
Question: Tally the dishes that have appeared on the menu for more than 100 years.
Evidence: appeared on the menu for more than 100 years = SUBTRACT(last_appeared, first_appeared) > 100;
SQL: SELECT T1.name FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id WHERE T1.last_appeared - T1.first_appeared > 100
Database: menu
Question: How many dishes have appeared on the menu in less than 5 years?
Evidence: appeared on the menu in less than 5 years = SUBTRACT(last_appeared, first_appeared) < 5;
SQL: SELECT COUNT(*) FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id WHERE T1.last_appeared - T1.first_appeared < 5
Database: menu
Question: Give me the name and menu price of dishes that were free.
Evidence: dishes that were free refers to lowest_price = 0;
SQL: SELECT T2.name, T1.price FROM MenuItem AS T1 INNER JOIN Dish AS T2 ON T2.id = T1.dish_id WHERE T2.lowest_price = 0
Database: menu
Question: How much does the dish on page 2 of menu ID 12474 cost?
Evidence: page 2 refers to page_number = 2;
SQL: SELECT T1.price FROM MenuItem AS T1 INNER JOIN MenuPage AS T2 ON T2.id = T1.menu_page_id WHERE T2.menu_id = 12474 AND T2.page_number = 2
Database: menu
Question: Among the dishes, how many of them were created between 2011-03-31 at 20:24:46 UTC and 2011-04-15 at 23:09:51 UTC.
Evidence: created between 2011-03-31 at 20:24:46 UTC and 2011-04-15 at 23:09:51 UTC refers to created_at between '2011-03-31 20:24:46 UTC' AND '2011-04-15 23:09:51 UTC';
SQL: SELECT SUM(CASE WHEN T2.created_at BETWEEN '2011-03-31 20:24:46 UTC' AND '2011-04-15 23:09:51 UTC' THEN 1 ELSE 0 END) FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id
Database: menu
Question: Who are the sponsors of the menu whose image full height is more than 10000 mm?
Evidence: image full height is more than 10000 mm refers to full_height > 10000;
SQL: SELECT T2.sponsor FROM MenuPage AS T1 INNER JOIN Menu AS T2 ON T2.id = T1.menu_id WHERE T1.full_height = 10000
Database: menu
Question: Write down the image ID, full height, and full width of the menu that were used in the "100TH ANNIVERSARY OF BIRTH OF DANIEL WEBSTER" event.
Evidence: FALSE;
SQL: SELECT T1.image_id, T1.full_height, T1.full_width FROM MenuPage AS T1 INNER JOIN Menu AS T2 ON T2.id = T1.menu_id WHERE T2.event = '100TH ANNIVERSARY OF BIRTH OF DANIEL WEBSTER'
Database: menu
Question: Under what events was the menu page's full width less than 2000 mm?
Evidence: full width less than 2000 mm refers to full_width < 2000;
SQL: SELECT T1.event FROM Menu AS T1 INNER JOIN MenuPage AS T2 ON T1.id = T2.menu_id WHERE T2.full_width = 2000
Database: menu
Question: Name the dishes that cost 180,000.
Evidence: cost 180,000 refers to price = 180000;
SQL: SELECT T1.name FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id WHERE T2.price = 180000
Database: menu
Question: What is the position coordinate on the page menu of the "Small Hominy" dish and how long did it appear?
Evidence: position coordinate = xpos, ypos; Small Hominy is a name of dish; how long it appear = SUBTRACT(last_appeared, first_appeared);
SQL: SELECT T2.xpos, T2.ypos, T1.last_appeared - T1.first_appeared FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id WHERE T1.name = 'Small Hominy'
Database: menu
Question: Calculate the image area of the page menu for the dish named "Baked Stuffed Mullet & Sauce Pomard". Please include the page number and image ID.
Evidence: image area = MULTIPLY(full_height, full_width);
SQL: SELECT T1.full_height * T1.full_width, T1.page_number, T1.image_id FROM MenuPage AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.menu_page_id INNER JOIN Dish AS T3 ON T2.dish_id = T3.id WHERE T3.name = 'Baked Stuffed Mullet & Sauce Pomard'
Database: menu
Question: How many dishes appeared more than once on a menu?
Evidence: appeared more than once on a menu refers to times_appeared > menus_appeared;
SQL: SELECT COUNT(*) FROM Dish WHERE times_appeared > Dish.menus_appeared
Database: menu
Question: How many menus sponsored by Krogs Fiske Restaurant were created in April 2015?
Evidence: sponsored by Krogs Fiske Restaurant refers to sponsor = 'Krogs Fiskerestaurant'; created in April 2015 refers to date like '2015-04%';
SQL: SELECT COUNT(*) FROM Menu WHERE date LIKE '2015-04%' AND sponsor = 'Krogs Fiskerestaurant'
Database: menu
Question: Which dish has the longest history?
Evidence: longest history refers to MAX(SUBTRACT(last_appeared, first_appeared));
SQL: SELECT name FROM Dish ORDER BY last_appeared - Dish.first_appeared DESC LIMIT 1
Database: menu
Question: On 1887-07-21, what was the event that lead to the creation of menu id 21380?
Evidence: On 1887-07-21 refers to date = '1887-07-21';
SQL: SELECT event FROM Menu WHERE date = '1887-07-21' AND id = 21380
Database: menu
Question: How many pages are there in the "Emil Kuehn" menu?
Evidence: Emil Kuehn is a name of menu;
SQL: SELECT SUM(CASE WHEN T1.name = 'Emil Kuehn' THEN 1 ELSE 0 END) FROM Menu AS T1 INNER JOIN MenuPage AS T2 ON T1.id = T2.menu_id
Database: menu
Question: How many menus include puree of split peas aux croutons?
Evidence: puree of split peas aux croutons is a name of dish;
SQL: SELECT SUM(CASE WHEN T1.name = 'Puree of split peas aux croutons' THEN 1 ELSE 0 END) FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id
Database: menu
Question: What are the names of the dishes with a stable price that were created in April of 2011?
Evidence: dishes with a stable price refers to highest_price is null; created in April of 2011 refers to SUBSTR(created_at,1,4) = '2011' and SUBSTR(created_at, 7, 1) = '4';
SQL: SELECT T1.name FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id WHERE SUBSTR(T2.created_at, 1, 4) = '2011' AND SUBSTR(T2.created_at, 7, 1) = '4' AND T1.highest_price IS NULL
Database: menu
Question: What is the name of the menu with the highest number of pages?
Evidence: highest number of pages refers to MAX(COUNT(page_number));
SQL: SELECT T1.name FROM Menu AS T1 INNER JOIN MenuPage AS T2 ON T1.id = T2.menu_id GROUP BY T2.menu_id ORDER BY COUNT(T2.page_number) DESC LIMIT 1
Database: menu
Question: Provide the menu page ids of all the menu that includes mashed potatoes.
Evidence: mashed potatoes is a name of dish;
SQL: SELECT T2.menu_page_id FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id WHERE T1.name = 'Mashed potatoes'
Database: menu
Question: Among the menus sponsored by Pacific Mail Steamship Company, how many menus have no more than 2 pages?
Evidence: sponsored by Pacific Mail Steamship Company refers to sponsor = 'PACIFIC MAIL STEAMSHIP COMPANY'; no more than 2 pages refers to COUNT(page_number) < = 2;
SQL: SELECT COUNT(*) FROM Menu AS T1 INNER JOIN MenuPage AS T2 ON T1.id = T2.menu_id WHERE T1.sponsor = 'PACIFIC MAIL STEAMSHIP COMPANY' GROUP BY T2.menu_id HAVING COUNT(T2.page_number) <= 2
Database: menu
Question: Among the menus that include milk, what is the menu page id of the menu that has the highest price?
Evidence: milk is a name of dish; highest price refers to MAX(price);
SQL: SELECT T1.menu_page_id FROM MenuItem AS T1 INNER JOIN Dish AS T2 ON T2.id = T1.dish_id WHERE T2.name = 'Milk' ORDER BY T1.price DESC LIMIT 1
Database: menu
Question: What is the menu id of the menu sponsored by Occidental and Oriental Steamship Company with the highest number of pages?
Evidence: sponsored by Occidental and Oriental Steamship Company refers to sponsor = 'OCCIDENTAL & ORIENTAL STEAMSHIP COMPANY'; highest number of pages refers to MAX(COUNT(page_number));
SQL: SELECT T2.menu_id FROM Menu AS T1 INNER JOIN MenuPage AS T2 ON T1.id = T2.menu_id WHERE T1.sponsor = 'OCCIDENTAL & ORIENTAL STEAMSHIP COMPANY' GROUP BY T2.menu_id ORDER BY COUNT(T2.page_number) DESC LIMIT 1
Database: menu
Question: List the positions of the dish "breaded veal cutlet with peas" on every menu where it appeared.
Evidence: positions = xpos, ypos; breaded veal cutlet with peas is a name of dish;
SQL: SELECT T2.xpos, T2.ypos FROM Dish AS T1 INNER JOIN MenuItem AS T2 ON T1.id = T2.dish_id WHERE T1.name = 'breaded veal cutlet with peas'
Database: menu
Question: What are the names of the dishes shown in the lower right corner of menu page 48706?
Evidence: shown in the lower right corner refers to xpos > 0.75 AND ypos > 0.75;
SQL: SELECT T2.name FROM MenuItem AS T1 INNER JOIN Dish AS T2 ON T2.id = T1.dish_id WHERE T1.xpos > 0.75 AND T1.ypos > 0.75 AND T1.menu_page_id = 48706