Forum Discussion

juju's avatar
juju
Helper III
9 years ago
Solved

MTD Calculation

  I am using the formula below to pull the MTD value from the previous day.  I'd like to make the value of the first day of each month blank - so it doesnt pull from the last day of the previous mon...
  • juju's avatar
    juju
    9 years ago

    All set. Managed to get it working with this :

     

    Previous Day MTDcALC = 
    IF ( FactTable[Date] = STARTOFMONTH(FactTable[Date]), BLANK(), 
        TOTALMTD (
            CALCULATE (
                CALCULATE ( 
                    SUM(FactTable[Value]),
                    FILTER (
                        FactTable,
                        FactTable[Channel]= "MyChannel"
                    )
               )
            ),
                PreviousDay (FactTable[Date])
            )
        )

     

    Thxxxx