Chapter 4 Exercise 43

43. What was the average discount (ListPrice – SalePrice) given on mountain bicycles in 2009? (3)

SELECT Bicycle.ModelType, Avg([ListPrice]-[SalePrice]) AS Discount
FROM Bicycle
WHERE (((Bicycle.OrderDate) Between #1/1/2009# And #12/31/2009#))
GROUP BY Bicycle.ModelType
HAVING (((Bicycle.ModelType)="Mountain"));