Forum Discussion
jersey417
Helper I
8 years agoRunning Sum Stops If Date is <= Today()
I've been beating my head around the following without getting a solution. I've read through the boards without finding a similar question. I created the following running sum calculated column ...
- 8 years ago
Hi jersey417
Try this
Running Total = IF ( Test1[Date] <= TODAY (), CALCULATE ( SUM ( test1[Produced_Qty] ), ALLEXCEPT ( test1, test1[Work_Center] ), test1[Date] <= EARLIER ( test1[Date] ) ) )
Zubair_Muhammad
Community Champion
8 years ago
Try
Running Total =
VAR myDate = test1[Date]
RETURN
IF (
Test1[Date] <= TODAY (),
CALCULATE (
SUM ( test1[Produced_Qty] ),
ALLEXCEPT ( test1, test1[Work_Center] ),
test1[Date] <= myDate
)
)jersey417
Helper I
8 years agoI'm not getting the returned error of "Function "CALCULATE" is not allowed as part of calculated column DAX expression on DirectQuery models. "