Page 22 - DAX-Formula-Reference-Guide-Enterprise-DNA_Neat
P. 22
DAX Formulas Reference Guide | Date and Time Functions (DAX)
Return Value:
A scalar value that represents the expression evaluated for all dates in the current
quarter to date given the dates in dates.
=TOTALQTD(SUM(InternetSales_USD[SalesAmount_USD]),DateTime[DateKey])
TOTALYTD Function (DAX)
Evaluates the year-to-date value of the expression in the current context.
Syntax: TOTALYTD(<expression>,<dates>[,<filter>][,<year_end_date>])
Parameter Definition
expression An expression that returns a scalar value.
dates A column that contains dates.
filter An expression that specifies a filter to apply to the current context.
(Optional)
year_end_date A literal string with a date that defines the year-end date. The default is
December 31st. (Optional)
Return Value:
A scalar value that represents the expression evaluated for the current year-to-date
dates.
=TOTALYTD(SUM(InternetSales_USD[SalesAmount_USD]),DateTime[DateKey],ALL(‘DateTi
me’), “6/30”)
=TOTALYTD(SUM(InternetSales_USD[SalesAmount_USD]),DateTime[DateKey]
+64 21 164 5508 | info@enterprisedna.co 22

