Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago
Solved

Running total dates too far on future or missing date

Hello,   I'm having trouble with running totals. My goal is to cut the DAX dates from the 2024 Q3 (red line), but dates go too far in future.   I'm having the following results with this DAX: M...
  • Anonymous's avatar
    Anonymous
    5 years ago

    This does result in similar situation:

     

     

    HOWEVER!

     

    Total sum = CALCULATE(SUM(FactTable[Value]),USERELATIONSHIP(FactTable[Date],'Date'[Date]))

    Measure =
    var _max =maxx(allselected(FactTable), FactTable[Date])
    return
    CALCULATE([Total sum],FILTER(ALL('Date'),'Date'[Date]<=MAX('Date'[date]) && MAX('Date'[Date]) <= _max ))

     

    This did help me to overcome this problem! Thank you so much!!