Question
For the Pizza Delivery Shop DB, (see Appendix), write SQL queries to answer each of the following questions. a) List all the last names, phone
For the Pizza Delivery Shop DB, (see Appendix), write SQL queries to answer each of the following questions.
a) List all the last names, phone numbers and zip codes of the customers. b) List information about only customers from zip code 11483. c) List all the customers that have no first address entered in the database d) List all products that are priced higher than $10 e) List all products that are priced between $5 and $9. f) List all customers whose last name starts with K g) What is the average price of a product? h) What is the highest price of a product? i) What is the total due for order-2003? j) Join the Product and OrderDetail tables so that the result contains the product name, product unit size, and product unit price, as well as the charged price. Do it for order-2000. k) List all the order and order details for each order made by customer with phone number 2127895450. l) Change the price of breadsticks to $3.00 m) Process the order for a new customer. (determine the process stages to actually satisfy a new customer, from the view point of DB processing, activities and manipulations.)
Appendix
1. Pizza Delivery Shop DB design. Relational schemas. Customer(CustomerPhoneKey [PK], LastName, FirstName, Address1, Address2, City, State, Zip). CustomerOrder(OrderKey [PK], OrderDate, OrderTime, CustomerPhoneKey [FK], EmployeeKey[FK]). Employee(EmployeeKey [PK], LastName, FirstName, HireDate). Product(ProductKey [PK], ProductName, UnitSize, UnitPrice). OrderDetail(OrderDetailKey [PK], OrderKey [FK], ProductKey [FK], OrderDetailQuantity, OrderDetailPriceCharged).
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started