Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Test on Database Query and Report (Customer Order System) When naming your queries and reports, please include query number and report number. For example, for

Test on Database Query and Report (Customer Order System) When naming your queries and reports, please include query number and report number. For example, for the first query, please name it query1: customers ordering products over 1 dollar. There are a total of 8 queries and 2 reports, plus 1 bonus query. 1. Query 1: What are the names of the customers who have ordered the products whose unit price is more than $1? The output should show customer first name, last name, brand name, product name, and unit price. 2. Query 2: What are the names of the customers who had ordered an activia (brand name) product in the first four months of 2012. The output should show customer names, order date and brand name. 3. Query 3: Update the inventory level of a certain product by prompting the user with the following three questions: what brand name it is?, what product name it is? and how much to increase by? The query will incorporate the answers to these questions at the query run time to make updates accordingly. All three user- prompt questions should be asked in the same sequence as stated in this question. 4. Query 4: How frequently (how many times) has each product been ordered (how many orders a product appeared on)? The output should include the headings of product id and order frequency. 5. Query 5: Show the products that need back order before July 20, 2012. Display the product name, brand name, order date, and back order of those products. 6. Query 6: What is the highest unit price of each brand? The output should show the headings of brand name and highest unit price. 7. Query 7: Show the names of customers who have ordered a certain brand of yogurt that has berry as part of product name. The query should prompt the user with the question, what brand is it? and incorporate the answer provided at the query run time to retrieve the answer. The query output should show names of customers, brand name and product name as the result. 8. Query 8: Given that an order can include one or more order items, what is the total sales amount of each order? The output should include the following headings: order id, total sales amount (which shows the amount in the currency format). 9. Bonus query: The manager would like to know the number of different brands of products each customer has ordered different brands of products, regardless of order quantity in each order. For example, if a customer ordered five units of the same Chobani product on an order placed on September 5th, 2012, it will be counted only one time instead of five times. The output should show customer id, first name, last name, brand name, product name, and brand order frequency. 10. Report 1: Based on the customer table, the order table, and the query 8 total sales amount, create a report that will show the names of customers in the first level, order id, order date in the second level, the total sales amount in the third level. The report should also include the sum of total sales for each customer, and at the end, the total sales for all customers. Make sure that all the information on the report is visible. Here is how the first screen of the report should look like (the next page). 2 11. Report 2: Use the product table and the order item table to create a report that will show an order summary of all the products by their brand name and product type. The order quantity should be summarized by the sum for each product and then each brand. The four pieces of information for the report, respectively, are brand name in the first level, product name in the second level, order id, and order quantity in the third level. Make sure that all the information on the report is visible. Here is an example In this example, the total quantity for each product is summed (as in the case of blueberry yogurt: 30) and the total quantity for each brand is summed as well (as in the case of chobanni: 127)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Handbook Of Anti Money Laundering

Authors: Dennis Cox

1st Edition

0470065745, 978-0470065747

More Books

Students also viewed these Finance questions

Question

Convert 7.50 ft 3 /s to gal/min.

Answered: 1 week ago