Forum Discussion

tcmem's avatar
tcmem
Regular Visitor
8 years ago
Solved

How to include Zeros in column value count

I'm trying to calculate a count of items in a column that are less than or equal to 12. For some reason, it's excluding the Zeros. How do I include the Zeros in my count? I'm also excluding blanks ba...
  • Vvelarde's avatar
    Vvelarde
    8 years ago

    tcmem

     

    Hi, you can use:

     

     

    Measure =
    COUNTROWS (
        FILTER ( Table1, ISBLANK ( Table1[Field2] ) = FALSE () && Table1[Field2] <= 12 )
    )

     

     

    Measure =
    CALCULATE (
        COUNT ( Table1[Field2] ),
        FILTER ( Table1; ISBLANK ( Table1[Field2] ) = FALSE () && Table1[Field2] <= 12 )
    )

     

    Regards

     

    Victor

    Lima - Peru