Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
3 years ago
Solved

Filtering data in a Running Total measure

I've got a calculated measure for a running total, but I'm trying to split it by [Value].

I want to say:
RT Type 1 = CALCULATE(SUM('Table'[Value]), FILTER(ALLSELECTED('Table'[DATE]), 'Table'[Date] <= 'MAX('Table'[Date])) && 'Table'[Type] = "1"

When I try this, it just gives me an error saying "Filter has been used in a True/False expression that is used as a table filter expression. This is not allowed."

I can't think of another solution. Thanks

  • Hi Anonymous 

    please try

    RT Type 1 =
    CALCULATE (
    SUM ( 'Table'[Value] ),
    ALLSELECTED ( 'Table' ),
    'Table'[Date] <= MAX ( 'Table'[Date] ),
    'Table'[Type] = "1"
    )

2 Replies

  • tamerj1's avatar
    tamerj1
    Icon for Community Champion rankCommunity Champion

    Hi Anonymous 

    please try

    RT Type 1 =
    CALCULATE (
    SUM ( 'Table'[Value] ),
    ALLSELECTED ( 'Table' ),
    'Table'[Date] <= MAX ( 'Table'[Date] ),
    'Table'[Type] = "1"
    )

    • Anonymous's avatar
      Anonymous
      Not applicable

      Such an easy solution. Haha, thanks!