Question: Consider the SQL query in Figure 1-19. a. How is Sales to Date calculated? b. How would the query have to change if Helen Jarvis

Consider the SQL query in Figure 1-19.
a. How is Sales to Date calculated?
b. How would the query have to change if Helen Jarvis wanted to see the results for all of the product lines, not just the Home Office product line?

SELECT Product.ProductID, Product.ProductDescription, Product.PRCurrentYearSalesGoal, (OrderQuantity • ProductPrice) A

SELECT Product.ProductID, Product.ProductDescription, Product.PRCurrentYearSalesGoal, (OrderQuantity ProductPrice) AS SalesToDate FROM Order.OrderLine, Product.ProductLine WHERE Order.OrderNumber = OrderLine.OrderNumber AND Product.ProductID = OrderedProduct.ProductID AND Product.ProductID = ProductLine.ProductID AND Product.ProductLineName = "Home Office";

Step by Step Solution

3.34 Rating (148 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

a SalesToDate is calculated by multiplying the quan... View full answer

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 Essentials Database Management Questions!