How to Count Unique Values in Pivot Table?


With the help of pivot tables, you may efficiently and effectively summarise and evaluate massive amounts of data. They give you the ability to aggregate and group data based on many dimensions and metrics, giving you insightful information about your data. Finding the distinct number of items inside a given category or field can be done by counting unique values in a pivot table. This might be useful in a variety of situations, including counting the quantity of distinctive consumers, distinctive products, or distinctive transactions.

In this article, we'll go through each step of how to make a pivot table and count the number of distinct values using various spreadsheet programmes or tools. Therefore, this article will arm you with the skills needed to effectively count unique values in your pivot tables regardless of your level of experience. Let's get going and unleash the potential of pivot tables to extract insightful knowledge from your data!

Count Unique Values in Pivot Table

Here we will first add a helper column to the source data and then create a pivot table to complete the task. So let us see a simple process to learn how you can count unique values in a pivot table in Excel.

Step 1

Consider an Excel sheet where the data in the sheet is similar to the below image.

First, in the data, add a new column named helper and enter the formula as =IF(SUMPRODUCT(($A$2:$A2=A2)*($B$2:$B2=B2))>1,0,1) and click enter. Then drag down using the autofill handle.

New Column > Formula > Enter > Drag.

Step 2

Then select the range of cells, click on pivot tables under Insert, and click OK.

Select Cells > Insert > Pivot Table > Ok.

Step 3

Then select the columns you want to show in the table, along with the helper column,

Conclusion

In this tutorial, we have used a simple example to demonstrate how you can count unique values in pivot table in excel to highlight particular set of data.

Updated on: 22-Aug-2023

182 Views

Kickstart Your Career

Get certified by completing the course

Get Started
Advertisements