You have a Fabric workspace that contains a warehouse named DW1. The warehouse contains the following tables and columns that store course purchases:
Table name | Column name |
---|---|
Purchase | CourseID |
Purchase | ModifiedDate |
Purchase | OrderQty |
Course | CourseID |
Course | Name |
You need to summarize order quantities as follows:
You have the following T-SQL query:
SELECT
YEAR(p.ModifiedDate) AS OrderDate,
c.Name AS CourseName,
SUM(p.OrderQty) AS OrderQty
FROM [Purchase] p
INNER JOIN [Course] c
ON c.CourseID = p.CourseID
GROUP BY ________________
ORDER BY OrderDate
How can you complete the T-SQL statement?
Choose the correct answer from the options below.
Explanations for each answer: