Forum Discussion
RenateBK
3 years agoHelper II
Need help: Cumulative sum function only returns total
Hello, Edit: Along with the solution I also identified another mistake I made. There was a mismatch between the formatting of my date table and the date column in my fact table (date/time vs dat...
- 3 years ago
Hi Renate,
Try this as a measure instead, making sure to use dDato fields in visuals, not fact table dates:
_cumulativeSum = VAR __cDate = MAX(dDato[Date]) RETURN CALCULATE( SUM(OversiktKurs[Deltagere kurs]), FILTER( ALLSELECTED(dDato), dDato[Date] <= __cDate ) )Pete
BA_Pete
3 years agoSuper User
Hi Renate,
Try this as a measure instead, making sure to use dDato fields in visuals, not fact table dates:
_cumulativeSum =
VAR __cDate = MAX(dDato[Date])
RETURN
CALCULATE(
SUM(OversiktKurs[Deltagere kurs]),
FILTER(
ALLSELECTED(dDato),
dDato[Date] <= __cDate
)
)
Pete