Forum Discussion

smpa01's avatar
smpa01
Icon for Community Champion rankCommunity Champion
5 years ago
Solved

Manipulating blanks from measure

My sample source data is following | key | |------|-------|---------|--------|-------| | site | month | service | pk | Index | | s1 | 1 | e | s1-...
  • Anonymous's avatar
    Anonymous
    4 years ago

    Hi smpa01 ,

    I have updated your sample pbix file(see attachment), please check whether that is what you want.

    1. Update the formula of your measure [maxMoFromTransaction] as below

    maxMoFromTransaction = 
    CALCULATE (
        MAX ( transcation[month] ),
        FILTER (
            ALLSELECTED ( 'transcation' ),
            'transcation'[site] = SELECTEDVALUE ( 'key'[site] )
                && 'transcation'[service] = SELECTEDVALUE ( 'key'[service] )
        )
    )

    2. Create another new measure and put it on the matrix to replace the measure [maxMoFromTransaction]

    Measure 4 = SUMX(GROUPBY('key','key'[site],'key'[service]),[maxMoFromTransaction])

    Best Regards