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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
Bill252
New Member

How to display all profiles attached to a product when it is selected (with DAX)

Hello team,

I am looking for a DAX formula that allows me, when a product is selected, to return the number of profiles working or assigned to this product.

Thank you in advance for your help.
Bill

 

UsineProduitProfilData
BOULOGNEVeloCloud Architect18
BOULOGNEVeloDevSecOps  270,9
BOULOGNECarEngineering 27
BOULOGNEBikeLead Dev72
BOULOGNECarProduct Owner57
BOULOGNEVéloManager9
BOULOGNEBikeUX/UI72
BOULOGNEmotoExpert 54
1 ACCEPTED SOLUTION
Bill252
New Member

The aim is to provide statistics on the number of engineers, technicians, experts, etc. assigned to each product manufactured.

 

My table is indeed clear, but what if you had a thousand products? The display won't be pretty on a graph, which is why I want to use a DAX.

 

I tested your formula and it didn't work. However, I modified @amitchandak's formula and it worked:

Count of Profiles = CALCULATE(DISTINCTCOUNT('Planned load'[Profile]),ALLSELECTED('Planned load'[Product]))

Thanks for your feedback.

View solution in original post

4 REPLIES 4
Bill252
New Member

The aim is to provide statistics on the number of engineers, technicians, experts, etc. assigned to each product manufactured.

 

My table is indeed clear, but what if you had a thousand products? The display won't be pretty on a graph, which is why I want to use a DAX.

 

I tested your formula and it didn't work. However, I modified @amitchandak's formula and it worked:

Count of Profiles = CALCULATE(DISTINCTCOUNT('Planned load'[Profile]),ALLSELECTED('Planned load'[Product]))

Thanks for your feedback.

amitchandak
Super User
Super User

@Bill252 , I think simple measure should do

DISTINCTCOUNT(ProfilesData[Profil])

Plot with Profil

 

or try

 

Count of Profiles =
CALCULATE(
DISTINCTCOUNT(ProfilesData[Profil]),
ALLSELECTED(ProfilesData)
)

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Hello @amitchandak , fFirst of all, thank you for your feedback.
However, my table call "Planned load". It has 5 columns:
1. Plant (Usine) ; 2. Product (Produit) ; 3. Profile (Profil) ; 4. Value (data); 5. Date

I've tested several formulas but they don't return what I want, for example :
Number of profils = COUNTROWS(FILTER('Planned load', 'Planned load'[Profile] = SELECTEDVALUE('Planned load[Products])))

or
Number of profils = CALCULATE(COUNT('Planned load'[Profile]), CROSSFILTER ('Planned load'[Products]))

 

Thank you in advance for your feedback

Bill252

Slim-
Frequent Visitor

Hello @Bill252,

I am not sure to understand why you want this count since your data are already well shaped so you can display it in any visual.

 

However, if you still need it for something else maybe you can try :

 

 

CALCULATE(COUNTROWS('Planned Load'),FILTER('Planned Load','Planned Load'[Produit]))

Regards

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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