Question: A restaurant database has the following tables: Order(OrderID, DateTime, DeliveryType, Discount) Dish(DishID, Name, Type, Price) Order Dish(OrderID(FK), DishID(FK), Quantity) (a) Write an SQL query that

 A restaurant database has the following tables: Order(OrderID, DateTime, DeliveryType, Discount)

A restaurant database has the following tables: Order(OrderID, DateTime, DeliveryType, Discount) Dish(DishID, Name, Type, Price) Order Dish(OrderID(FK), DishID(FK), Quantity) (a) Write an SQL query that show dishes with type "Soup" and that between 5 and 10 euro. (5 marks) (b) Write an SQL query that calculates the total number of items (the sum of all quantities) in an order with OrderID 187. (6 marks) (c) Write an SQL query that shows details of Orders that have a dish named "Aromatic Duck" (7 marks) (d) Write an SQL query that removes all items of type "Beverage" from an Order with OrderID 251. (7 marks) Total (25 marks)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!