Forum Discussion
Line graph question
- 5 years ago
Hi, RonaldvdH
Based on your description, I created data to reproduce your scenario. The pbix file is attached in the end.
You may create a measure as below.
Result = CALCULATE( SUM('Table'[Value]), FILTER( ALL('Table'), [YearWeek]<=MAX('Table'[YearWeek]) ) )Result:
Best Regards
Allan
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
RonaldvdH , if you are using a date table and week is part of that then it will give cumulative with dates
example
Cumm Sales = CALCULATE(SUM(Table[value]),filter(allselected(Date),Date[Date] <=max(Date[Date])))
or
Cumm Sales = CALCULATE(SUM(Table[value]),filter(allselected(Table),Table[Date] <=max(Table[Date])))
else create a week rank in table and use that
Week Rank = RANKX(all('Date'),'Date'[Year Week],,ASC,Dense) //YYYYMM format
Cumm Sales = CALCULATE(SUM(Table[value]),filter(allselected(Date),Date[Week Rank] <=max(Date[Week Rank])))
- RonaldvdH5 years agoPost Patron
I dont have a date table so is there an option to work with the data i do have ?
I have a table with dates in them and i use a formula to convert (to a string) the dates into a week number format YYYY-MM