Forum Discussion
ArbWare
2 years agoNew Member
Group Running total for date and type
Working on this, and i'm stuumped I can get to group riunning toital by date, but not by Type/Date combined Any help would be sorely appreciated Type Date Value a 1/1/2022 1 a 2/1...
- 2 years ago
Thank you all for the guidance,
I found the desired result through the use of "AllExcept"
ToDate=CALCULATE (
SUM ( Table1[Value] ),
FILTER (
ALLEXCEPT ( Table1, Table1[Type] ),
Table1[Date] <= MAX ( Table1[Date] )
)
)Just preliminary, but i think it does what i'm looking for...
Love the forum.. thanks for giving the guidance that led me to a solution that works.
newtodax
2 years agoFrequent Visitor
Try using the following measure and see if that works.
Running Total by Category Group =
VAR CategoryGroupFilter = SELECTEDVALUE(Table1[Type])
VAR RunningTotal =
IF(
CategoryGroupFilter = "a",
SUMX(
FILTER(
ALL(Table1),
Table1[Type] = "a" &&
Table1[Date] <= MAX(Table1[Date])
),
Table1[Value]
),
IF(
CategoryGroupFilter = "b",
SUMX(
FILTER(
ALL(Table1),
Table1[Type] = "b" &&
Table1[Date] <= MAX(Table1[Date])
),
Table1[Value]
),
BLANK()
)
)
RETURN
RunningTotal