The following restaurant menu items are in a table called restaurant_menu: Meal Breakfast Breakfast MenulD 1...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
The following restaurant menu items are in a table called restaurant_menu: Meal Breakfast Breakfast MenulD 1 2 3 4 15 6 18 9 10 CaloriesID 1 2 3 14 5 17 18 19 Lunch Lunch Lunch Dinner Dinner Dinner Dessert 10 Item Oatmeal Omelette Cost 5 7 Clam Chowder 10 12 Steak Burger 19 Clam Chowder 10 12 Dessert The following table shows the calorie information on a variety of restaurant menu items in a table called restaurant_calories: Steak Burger Apple Pie Chocolate Cake Calories 500 300 650 450 700 19 550 700 750 600 900 6 CaloriesID 2 1 3 15 3 5 7 Calories 300 600 650 700 700 650 700 700 450 300 75 250 280 300 350 350 300 250 300 550 Calories_From_Fat 3. 4. 5. You are given 2 tables, each called table1, table2. Each table consists of 1 column, col1. Each table has 5 rows per column. The column consists of the values of 1,2,3,4,5. Hence both tables look exactly like this: col 1 1 2 3 Write one query that does the following: a. Displays only the list of items that appear only once on the menu 4 5 Write one query that displays the meal and Item columns. Add a new column called average_meal_cost farthest to the right, which gives the overall average cost of all items associated with a meal. For example, the first 2 rows would show 6 in the new column. Write a query that joins every row of table1 to every row of table2. After writing the query, how many total rows will there be, assuming there is no filtering? The following restaurant menu items are in a table called restaurant_menu: Meal Breakfast Breakfast MenulD 1 2 3 4 15 6 18 9 10 CaloriesID 1 2 3 14 5 17 18 19 Lunch Lunch Lunch Dinner Dinner Dinner Dessert 10 Item Oatmeal Omelette Cost 5 7 Clam Chowder 10 12 Steak Burger 19 Clam Chowder 10 12 Dessert The following table shows the calorie information on a variety of restaurant menu items in a table called restaurant_calories: Steak Burger Apple Pie Chocolate Cake Calories 500 300 650 450 700 19 550 700 750 600 900 6 CaloriesID 2 1 3 15 3 5 7 Calories 300 600 650 700 700 650 700 700 450 300 75 250 280 300 350 350 300 250 300 550 Calories_From_Fat 3. 4. 5. You are given 2 tables, each called table1, table2. Each table consists of 1 column, col1. Each table has 5 rows per column. The column consists of the values of 1,2,3,4,5. Hence both tables look exactly like this: col 1 1 2 3 Write one query that does the following: a. Displays only the list of items that appear only once on the menu 4 5 Write one query that displays the meal and Item columns. Add a new column called average_meal_cost farthest to the right, which gives the overall average cost of all items associated with a meal. For example, the first 2 rows would show 6 in the new column. Write a query that joins every row of table1 to every row of table2. After writing the query, how many total rows will there be, assuming there is no filtering?
Expert Answer:
Related Book For
Operations management processes and supply chain
ISBN: 978-0136065760
9th edition
Authors: Lee J Krajewski, Larry P Ritzman, Manoj K Malhotra
Posted Date:
Students also viewed these economics questions
-
The Internal Revenue Service provides information on a variety of tax issues in its publication series. These publications can be found on the IRS World Wide Web site...
-
The Internal Revenue Service provides information on a variety of tax issues in its publication series. These publications can be found on the IRS Web site (www.irs.gov/formspubs/index.html). Go to...
-
A database stores data in a table called Cars. The table structure includes fields called Colour, Engine Size and Number of Doors. Write an SQL query-by-example which searches for red or blue cars,...
-
Consider two mutually exclusive investment projects: A 1 and A2. Each project has the same service life, and the present worth of each component value (B, I, and C) is computed at 10% as follows:...
-
Light that has a wavelength of 668 nm passes through a slit 6.73 10-6 m wide and falls on a screen that is 1.85 m away. What is the distance on the screen from the center of the central bright...
-
Find the result of operating with (1/r 2 ) (d /dr) (r 2 d /dr) + 2/r on the function Ae br . What must the values of A and b be to make this function an eigenfunction of the operator?
-
Compute the missing amount for Jones Corporation. You will need to work through total stockholders equity. Requirements 1. Did Jones earn a net income or suffer a net loss for the year ? Compute the...
-
A jet plane at take-off can produce sound of intensity 10.0 W 1m2 at 30.0 m away. But you prefer the tranquil sound of normal conversation, which is 1.0W/m2. Assume that the plane behaves like a...
-
Exhibit 2 Balance Sheets at December 31, 1993-1995, and March 31, 1996 (thousands of dollars) 1st Quarter 1993 1994 1995 1996 Cash $ 43 $ 52 $ 56 $ 53 Accounts receivable, net 306 411 606 583...
-
There are only two risky assets (stocks) A and B in the market. Mean 20% B 10% The returns on the two assets have zero correlation. A Standard Deviation 10% 5% A. Assume that there is no risk-free...
-
Mark on his retirement date will have $2,250,000 in his retirement account. He plans to annually withdraw some money from his retirement account on the last day of the year. He will reinvest the...
-
What is the logic behind the ARCH method for forecasting yield volatility?
-
What is the breakeven inflation rate and what information does it convey?
-
a. What is implied volatility? b. What are the problems associated with using implied volatility as a measure of yield volatility?
-
How do expropriation and confiscation differ?
-
What is the relationship between nominal interest rates, real interest rates, and expected inflation?
-
4. 5. Determine the components of the force shown in the a and b directions. Also determine the a and b projections of the force. 1400 lb K 3000 N zo 30 b Using rectangular components determine the...
-
What are some of the features of the Unified Process (UP)?
-
Terminator, Inc. manufactures a motorcycle part in lots of 250 units. The raw materials cost for the part is $150, and the value added in manufacturing unit from its components is $300, for a total...
-
The Giant Farmer Company processes food for sale in discount food stores. ft has two plants: one in Chicago and one in Houston. The company also operates warehouses in Miami. Florida: Denver,...
-
You are designing a grocery delivery business. Via the Internet, your company will offer staples and frozen foods in a large metropolitan area and then deliver them within a customer-defined window...
-
Find the force transmitted to the base of a viscously damped system subjected to a harmonic force, in the steady state, by using the relation \(f_{T}=F_{0} \cos \omega t-m \ddot{x}\) instead of...
-
A single-story building frame is subjected to a harmonic ground acceleration, as shown in Fig. 3.57. Find the steady-state motion of the floor (mass \(m\) ). Figure 3.57:- 22 -x(t) m (!) - A cos cot...
-
Find the horizontal displacement of the floor (mass \(m\) ) of the building frame shown in Fig. 3.57 when the ground acceleration is given by \(\ddot{x}_{g}=100 \sin \omega t \mathrm{~mm} /...
Study smarter with the SolutionInn App