Question 1 of 30
A company wants to analyze its sales data to determine the average sales per product category over the last year. The sales data is stored in a table named `Sales`, which includes columns for `ProductCategory`, `SalesAmount`, and `SalesDate`. The company needs to create a DAX measure that calculates the average sales amount for each product category, but only for sales that occurred in the last 12 months. Which DAX formula would correctly achieve this?
`AverageSalesLastYear = AVERAGEX(FILTER(Sales, Sales[SalesDate] >= EDATE(TODAY(), -12)), Sales[SalesAmount])`
`AverageSalesLastYear = AVERAGE(Sales[SalesAmount])`
`AverageSalesLastYear = CALCULATE(AVERAGE(Sales[SalesAmount]), Sales[SalesDate] >= DATE(YEAR(TODAY()) - 1, MONTH(TODAY()), DAY(TODAY())))`
`AverageSalesLastYear = SUM(Sales[SalesAmount]) / COUNT(Sales[SalesAmount])`

Preparing for Microsoft PL-300 Microsoft Power BI Data Analyst? Now land the interview.

73% of qualified candidates get rejected because of weak resumes. Build an ATS-optimized, recruiter-ready resume in under 5 minutes - free to start.

Build My Resume Free