Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

DAX SUM Positive Numbers Only From Multiple Columns

I need to SUM positive numbers only from multiple columns. Tried Calculate with Sum / Sumx but came up with errors.

Appreciate any help, thanks. 

 

 

 

2 Replies

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

    Hi Anonymous 

     

    Sum pos only = SUMX('Table',IF('Table'[Column1]>0,'Table'[Column1],0)+IF('Table'[Column2]>0,'Table'[Column2],0))

    You were on the right track.
    Let me know if you have any questions.

    If this solves your issues, please mark it as the solution, so that others can find it easily. Kudos are nice too.
    Nathaniel



     

    • Anonymous's avatar
      Anonymous
      Not applicable

      Nathaniel_C I forgot to add IF. Thank you, it worked:)