Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

The toy distributor, referred to as ABC Toys, where you currently work, wants to evaluate the different scenarios below. Using the tables provided by the

The toy distributor, referred to as ABC Toys, where you currently work, wants to evaluate the different scenarios below. Using the tables provided by the Sams Teach Yourself SQL in 10 Minutes that we used in class, please answer the following questions.

Question 1

The head of procurement is considering trimming the number of vendors they work with down to the top vendor by the total number of products we currently sell. What would be the financial impact on sales if a company only worked with the top vendor by product count?

To answer this question:

Create a query that includes vend_name, ven_id, and product_count by joining the product and vendor tables. Be sure that it summarizes the total number of products by each vendor and is sorted correctly.

Create a query that sums the total dollar amount sold by each vendor by joining the vendor, product, and order items table together. Be sure that it summarizes the total dollar amount sold by each vendor and is sorted correctly.

Question 2

The director of finance has noticed that some customers are getting discounts without approval. What is the total amount that has been discounted and which orders were discounted the most? They have requested to see the discounts by both the $ amount and %.

To answer this question:

Create a query that includes the order number, actual total price (by using the item_price), original total price (by using prod_price), discount (original price - actual price) and the discounted % (discount/original price). Be sure the discounted % column is formatted correctly and rounded to one decimal place. Also, ensure your results are summarized by order number.

Create a second query that summarizes the total discount from the above query.

Question 3

With the recent problems plaguing supply chains around the world, the head of strategy is considering only selling products from vendors located in Michigan (MI). What would the impact be financially to the company and what products would we contue to sell?

To answer this question:

Create a query that includes vendor id and vendor name that is filtered to all vendors located in Michigan.

Create a query that inclues product id, product name and product description for all vendors located in Michigan.

Create a query that summarizes the total order price by state.

image text in transcribedimage text in transcribedimage text in transcribed

Queries

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_2

Step: 3

blur-text-image_3

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

More Books

Students also viewed these Databases questions

Question

Solve the initial-value problem. xy' = y + x 2 sin x, y() = 0

Answered: 1 week ago