Write a query that will be used for invoices. The query needs to show Order Line level
Fantastic news! We've Found the answer you've been seeking!
Question:
Write a query that will be used for invoices. The query needs to show Order Line level information, and then the final row will show the Order Totals. To earn the extra credit, you must use the UNION set operator.
The OrderLine level columns should include OrderID, OrderDate, ProductName, Price, Quantity, and LineTotal.
The Order Total level information should include OrderID, OrderDate, and OrderTotal. For ProductName, show "Order Total." Align OrderTotal with LineTotal.
Hints:
- Write a query that shows 1 row for each Order Line from OrderID 6 with the columns specified above.
- Write a separate query with 1 row showing the Order Total with the columns specified above.
- Make sure the queries are Union Compatible
- Combine the queries by adding the UNION keyword between them
Related Book For
Income Tax Fundamentals 2013
ISBN: 9781285586618
31st Edition
Authors: Gerald E. Whittenburg, Martha Altus Buller, Steven L Gill
Posted Date: