Forum Discussion

Smon's avatar
Smon
Regular Visitor
3 years ago

Sum score ignoring negative score

Hi team, 

I have a question relevant to Calculation of Power BI desktop. How to use DAX to make sum score without(ignore) negative value (-1)? However, the negative value (-1) it should show off when we click drilldown to see detail scoring of each indicator?

Notice: following this picture the total score should be 35not 34.

1 Reply

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

    Smon Maybe:

    Measure = 
      IF(
        HASONEVALUE('Table'[__Index]),
        SUM('Table'[Score],
        SUMX(FILTER('Table',[Score] > 0),[Score])
      )