Forum Discussion
admin11
Memorable Member
5 years agowhich YTD expression is better ?
Hi All
Below both expression work fine :-
_YTD_REV_ROBERT =
var _max = today()
return
calculate(TOTALYTD([AMOUNT],'Date'[Date]),GL[1_REV] = "REV",filter('Date','Date'[Date]<=_max))
_YTD REV_AMIT = CALCULATE(CALCULATE(GL[AMOUNT],DATESYTD('Date'[Date],"12/31")), GL[1_REV] = "REV")
May i know you prefer to use which one and why ?
Paul Yeo
admin11 , ideally the first one should display data till today only.
With TOTALYTD not need to calculate.
Both functions are almost the same.
I prefer to use calculate to I use DATESYTD more often
1 Reply
- amitchandak
Super User
admin11 , ideally the first one should display data till today only.
With TOTALYTD not need to calculate.
Both functions are almost the same.
I prefer to use calculate to I use DATESYTD more often