How to count the number of customers ordering at an item - pivot table

Lyndall Bradley
Lyndall Bradley used Ask the Experts™
on
Column A: - Unique identification number of product
Column B: Departments ordering


I would like to count the number of  departments ordering  a unique product in Colum A
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
ShumsManaging Director/Excel VBA Developer
Distinguished Expert 2018

Commented:
Hi,

Sample workbook would be helpful.
hmm ... why pivot ?

select A,count(B) from table group by A
Managing Director/Excel VBA Developer
Distinguished Expert 2018
Commented:
Probably like this?
You can filter the ID's and pivot will list the count as per department.
Count-Unique-IDs.xlsx
Ensure you’re charging the right price for your IT

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden using our free interactive tool and use it to determine the right price for your IT services. Start calculating Now!

oups : missed the excel part ;) sorry
if you need a formula for a specific product, something like this should do : count(if(A1:A100 = "myproduct",B1:B100))

Author

Commented:
Thank-you for your replies.

The attached workbook. I would like to know how many times the customers in Colum B orders column A. Thank-you for your time and assistance.
you'd need to replace the "sum" by a "count" in the calculated data ( or add an extra column ).
click on the pivot and find where you can add a new "value" or "set of values" which will actually ask for the type of value ( sum, count, count unique ... ) and add the corresponding extra column.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial