Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Create a view named product_summary. This view should return summary information

ID: 3692882 • Letter: C

Question

Create a view named product_summary. This view should return summary information about each product. Each row should include product_id, order_count (the number of times the product has been ordered) and order_total (the total sales for the product). Query 7: Write a SELECT statement that uses the view that you created in query 6 to get total sales for the five best selling products. Query 8: Creates a view named cheap_products_view whose subquery retrieves products with prices less than $15. Query 9: Write a SELECT statement that returns all the columns from the cheap_products_view view that you created in query 8. Query 10: Creates a view named cheap_products_view2 whose subquery retrieves products with prices greater than $50. Add a CHECK OPTION constraint.

Explanation / Answer

CREATE VIEW [product_summary] AS
SELECT product_id , order_count , order_total FROM Product;

QUERY 7:

SELECT TOP 5 order_total  FROM [product_summary] ;

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote