Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
7 years ago
Solved

COUNTIFS Functionality in DAX

Trying to find a DAX equivilent to:

=IF(COUNTIFS(A:A,$A2,B:B,">="&0)>0,"OK","Not Ok")

 

This excel formula gives me the result in column C

 

  • Anonymous

     

    You can use this column

     

    Column =
    IF (
        CALCULATE (
            COUNTROWS ( tABLE1 ),
            FILTER ( ALLEXCEPT ( Table1, Table1[Customer] ), [Date Diff] > 0 )
        ),
        "ok",
        "NOT ok"
    )
    

2 Replies

  • Zubair_Muhammad's avatar
    Zubair_Muhammad
    Community Champion

    Anonymous

     

    You can use this column

     

    Column =
    IF (
        CALCULATE (
            COUNTROWS ( tABLE1 ),
            FILTER ( ALLEXCEPT ( Table1, Table1[Customer] ), [Date Diff] > 0 )
        ),
        "ok",
        "NOT ok"
    )
    
    • Anonymous's avatar
      Anonymous
      Not applicable

      Thank you!