Question: Write a SQL statement that returns one row for each category and calculate total sum and total discount of the products sold in that category:

 Write a SQL statement that returns one row for each category

Write a SQL statement that returns one row for each category and calculate total sum and total discount of the products sold in that category: The category_name column from the Category table Distinct product count that was sold in each category The Sum of the (Item Price multiplied by the quantity) in the Order_Items table per Category The Sum of the (Discount amount multiplied by the quantity) in the Order_items table per Category Sort the result set in descending sequence by the item price total for each category

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!