Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

DAX/M Query

Hi Team,   Good Morning!   I need Sumif calculation for YDT process insert into summary table, see the below screenshot,    Summary Table- need to add "YTD-20" column for few months sum calcula...
  • v-alq-msft's avatar
    6 years ago

    Hi, Anonymous 

     

    Based on your description, I create data to reproduce your scenario.

    Table:

     

    You may create a measure as below.

    Result = 
    CALCULATE(
        SUM('Table'[Value]),
        FILTER(
            ALL('Table'),
            'Table'[Date]<=MAX('Table'[Date])&&
            'Table'[GHT] = SELECTEDVALUE('Table'[GHT])
        )
    )

     

    Then you may use a matrix visual to diplay the result.

     

    Best Regards

    Allan

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.