Forum Discussion

David1955's avatar
David1955
Copper Contributor
Sep 30, 2019

pivot table counting zero

I want to use the count function in a pivot table

 

but to not count zeros!

 

Help

1 Reply

  • David1955 

    You may use CounfIf function.

    So if you are counting the values in column A which are not zeros, you may try...

    =COUNTIF(A:A,">0")

     

    Or if you want to count in the Pivot Table itself, while inserting the Pivot Table, check the box for "Add this data to the Data Model" and then create a Measure to count except zeros using of the following DAX formula.

     

    "Count >0"
    =CALCULATE(COUNTROWS(Table1),Table1[Qty]>0)

     

    "Count >0"
    =CALCULATE(COUNT(Table1[Qty]),Table1[Qty]>0)

     

     

     

Resources