Forum Discussion
Help with DAX for cummulative data
- 5 years ago
Hi newbie9292 ,
Please use the following measure:
KUM_LY_AE = CALCULATE (SUM(AE_2020[AuftrEing]),FILTER (ALLSELECTED(Date_dim[Date]),Date_dim[Date] <= MAX (Date_dim[Date])&&MONTH(Date_dim[Date])<=MONTH(MAX (Date_dim[Date]))))It works well based on my test data.
You can also refer to my test pbix.
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Best Regards,
Dedmon Dai
Hi newbie9292
This column here, from which Table is it added to the visual?
And how the Dim_Date and AE_2020 tables are connected?
- newbie92925 years agoHelper II
Hello Amine,
Thanks for your reply.
This is how my model looks like :
This is how the tables are connected :
- PaulDBrown5 years agoCommunity Champion
You need to set the data type for you date column in the fact tables to "date". It looks like they are set to type "whole number".
also make sure the fields in your visuals and slicer all come from the date table.
- newbie92925 years agoHelper II
Hello PaulDBrown ,
Thanks for your reply. Yes the columns are in date format now and the slicers are coming from the date table but still the issue remains.