Forum Discussion
RATING WISE EMPLOYEE COUNT
- 1 year ago
Hi PRADEEPJAAN,
You can achieve this by creating a DAX measure that counts the number of employees based on the selected rating in the slicer.
Solution: Create a Measure
Use the following DAX formula:
Emp Count by Rating =
VAR SelectedRating = SELECTEDVALUE('Table'[RATING])
RETURN
CALCULATE(
COUNT('Table'[EMP CODE]),
'Table'[RATING] = SelectedRating
)Steps to Implement:
- Load your data into Power BI.
- Create a slicer using the RATING column.
- Create a card visual and apply the Emp Count by Rating measure.
- Now, when you select a rating in the slicer, the card will show the count of employees with that rating.
Expected Output:
- Selecting Rating = 1 in the slicer β The card will show 3 (employees: 1001, 1003, 1009).
- Selecting Rating = 2 β The card will show 2 (employees: 1002, 1006).
- And so onβ¦
π I hope this solution helps you unlock your Power BI potential! If you found it helpful, click 'Mark as Solution' to guide others toward the answers they need.
π‘ Love the effort? Drop the kudos! Your appreciation fuels community spirit and innovation.
π As a proud SuperUser and Microsoft Partner, weβre here to empower your data journey and the Power BI Community at large.
π Curious to explore more? [Discover here].
Letβs keep building smarter solutions together!
Hi PRADEEPJAAN,
You can achieve this by creating a DAX measure that counts the number of employees based on the selected rating in the slicer.
Solution: Create a Measure
Use the following DAX formula:
Emp Count by Rating =
VAR SelectedRating = SELECTEDVALUE('Table'[RATING])
RETURN
CALCULATE(
COUNT('Table'[EMP CODE]),
'Table'[RATING] = SelectedRating
)
Steps to Implement:
- Load your data into Power BI.
- Create a slicer using the RATING column.
- Create a card visual and apply the Emp Count by Rating measure.
- Now, when you select a rating in the slicer, the card will show the count of employees with that rating.
Expected Output:
- Selecting Rating = 1 in the slicer β The card will show 3 (employees: 1001, 1003, 1009).
- Selecting Rating = 2 β The card will show 2 (employees: 1002, 1006).
- And so onβ¦
π I hope this solution helps you unlock your Power BI potential! If you found it helpful, click 'Mark as Solution' to guide others toward the answers they need.
π‘ Love the effort? Drop the kudos! Your appreciation fuels community spirit and innovation.
π As a proud SuperUser and Microsoft Partner, weβre here to empower your data journey and the Power BI Community at large.
π Curious to explore more? [Discover here].
Letβs keep building smarter solutions together!