Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
MP87
New Member

Help with Counting

I have data that identifies internal part numbers, along with manufacturer names and part numbers. I am trying to provide information on how many, and what, items have a certain number of parts listed. For example, one user wants a report on all internal part numbers with only one manufacturer, while another user wants a listing of all internal numbers with either 2 or 3 manufacturers.

 

An example of my data is as follows:

 

Internal Part NumberManufacturerMFG Part Number
123ABC789
123XYZ789
456ABC1010
654ABC555
654XYZ888
654HIJ4545

 

I want the user to be able to select 1 manufacturer, and see just 456. Select 2 and see 123. Select more than 1 and see 123 and 456.

 

Thanks in advance

1 ACCEPTED SOLUTION
Ritaf1983
Super User
Super User

Hi @MP87 

If I understood you correctly, you can add a calculated column that will count the manufacturers for every part.
The formula that you can use for this :

count manufacturers for part = CALCULATE(DISTINCTCOUNT('Table'[Manufacturer]), ALLEXCEPT('Table','Table'[Internal Part Number]))
Ritaf1983_0-1712894459164.png

and use this column as a slicer :

Ritaf1983_1-1712894492398.png

the pbix is attached

If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

View solution in original post

1 REPLY 1
Ritaf1983
Super User
Super User

Hi @MP87 

If I understood you correctly, you can add a calculated column that will count the manufacturers for every part.
The formula that you can use for this :

count manufacturers for part = CALCULATE(DISTINCTCOUNT('Table'[Manufacturer]), ALLEXCEPT('Table','Table'[Internal Part Number]))
Ritaf1983_0-1712894459164.png

and use this column as a slicer :

Ritaf1983_1-1712894492398.png

the pbix is attached

If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors