What should you do?

You have a sales system that contains the tables shown in the following table.

The Date table is marked as a date table. DateID is the date data type.
You need to create an annual sales growth percentage measure.
Which DAX expression should you use?
A. SUM(sales[sales_amount]) – CALCULATE(SUM(sales[sales_amount]), SAMEPERIODLASTYEAR(‘Date'[DateID])
B. (SUM(‘Sales'[sales_amount]) – CALCULATE(SUM(‘Sales'[sales_amount]), SAMEPERIODLASTYEAR(‘Date'[DateID]))) / CALCULATE(SUM(‘Sales'[sales_amount]), SAMEPERIODLASTYEAR(‘Date'[DateID]))
C. CALCULATE(SUM(sales[sales_amount]), DATESYTD(‘Date'[DateID]))
D. CALCULATE(SUM(sales[sales_amount]), SAMEPERIODLASTYEAR(‘Date'[DateID])) Correct Answer: B Section: (none) Explanation
Explanation/Reference:
Explanation:
SAMEPERIODLASTYEAR returns a table that contains a column of dates shifted one year back in time from the dates in the specified dates column, in the current context.
Reference:
https://docs.microsoft.com/en-us/dax/sameperiodlastyear-function-dax
[/showhide]

microsoft-exams

Leave a Reply

Your email address will not be published. Required fields are marked *


The reCAPTCHA verification period has expired. Please reload the page.