Forum Discussion
Yoshimitsu411
4 years agoResolver I
DAX Month Cummulative using SUMX RANKX
Hello I am trying to work out the cumulative amounts for each month using the following dax queries with Rankx. Month Numbers =
SWITCH([Total Sales Ranking by Month],
"JAN", 1,
"FEB", 2,
"M...
amitchandak
4 years agoSuper User
Yoshimitsu411 , As you have date and you want a yearly total then you can use datesytd
example
YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD('Date'[Date],"12/31"))
For Cumulative with help from date table
Cumm Sales = CALCULATE(SUM(Sales[Sales Amount]),filter(allselected(date),date[date] <=max(date[Date])))