Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi All,
I am working on a HR dataset, which has users, skills, departments and their ratings data.
One user can have different ratings in different departments and in different skills.
I have hierarchy slicers which have Skills -> Ratings separately for each departments.
If i select ratings from two different departments(from two department slicers) and two different skills, it has to dyanmically be displayed in a matrix visual with selected skill and rating.
Data:
User | Dept | Skill | Rating |
Anita | Department 1 | A | 1 |
Deepak | Department 1 | A | 2 |
Anita | Department 1 | B | 1 |
Deepak | Department 1 | B | 2 |
Manish | Department 1 | B | 3 |
Vivek | Department 2 | c | 1 |
Manish | Department 2 | D | 1 |
Anita | Department 2 | D | 2 |
Output :
Say, i have selected Skill A and Rating 1 (Dept Slicer 1) & Skill D and Rating 2 (Dept Slicer 2)
User name | Skill A | Skill D |
Anita | 1 | 2 |
Could anyone help on this
Solved! Go to Solution.
Hi @AishwariyaV ,
You need to create two table to make the filtering of your data I have used the following codes:
Slicer 1 = SUMMARIZE('Table','Table'[Rating],'Table'[Skill])
Slicer 2 = SUMMARIZE('Table','Table'[Rating],'Table'[Skill])
Now create the following measure:
Rating _Selected _ skills =
IF (
(
SELECTEDVALUE ( 'Table'[Skill] )
IN VALUES ( 'Slicer 1'[Skill] )
&& SELECTEDVALUE ( 'Table'[Rating] ) IN VALUES ( 'Slicer 1'[Rating] )
)
|| (
SELECTEDVALUE ( 'Table'[Skill] )
IN VALUES ( 'Slicer 2'[Skill] )
&& SELECTEDVALUE ( 'Table'[Rating] ) IN VALUES ( 'Slicer 2'[Rating] )
),
MAX ( 'Table'[Rating] )
)
Now format your matrix with the following way:
Result below and in attach PBIX file:
Regards
Miguel Félix
Proud to be a Super User!
Check out my blog: Power BI em PortuguêsHi @AishwariyaV ,
You need to create two table to make the filtering of your data I have used the following codes:
Slicer 1 = SUMMARIZE('Table','Table'[Rating],'Table'[Skill])
Slicer 2 = SUMMARIZE('Table','Table'[Rating],'Table'[Skill])
Now create the following measure:
Rating _Selected _ skills =
IF (
(
SELECTEDVALUE ( 'Table'[Skill] )
IN VALUES ( 'Slicer 1'[Skill] )
&& SELECTEDVALUE ( 'Table'[Rating] ) IN VALUES ( 'Slicer 1'[Rating] )
)
|| (
SELECTEDVALUE ( 'Table'[Skill] )
IN VALUES ( 'Slicer 2'[Skill] )
&& SELECTEDVALUE ( 'Table'[Rating] ) IN VALUES ( 'Slicer 2'[Rating] )
),
MAX ( 'Table'[Rating] )
)
Now format your matrix with the following way:
Result below and in attach PBIX file:
Regards
Miguel Félix
Proud to be a Super User!
Check out my blog: Power BI em PortuguêsCheck out the July 2025 Power BI update to learn about new features.
User | Count |
---|---|
73 | |
72 | |
38 | |
31 | |
26 |