Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
Hi so I have 2 tables connected to each other through Employee ID. One is HR list of employees and second is Violations.
I have created a slicer by using employee’s name so anyone can query a particular employee and they will get count of violations of an employee.
Each employee belongs to a particular function. I want to create a measure which also tells me the number of employees in the same function who have had any kind of violations.
So for Eg - If I have selected Jamie Franco in the slicer and since he belongs to GL Global function, I should also be able to see how many employees in GL Global function had violations
Hi @gopalm
You need a measure that retains the visible value(s) of Employee Function but otherwise clears filters on Employee, then calculates the number of violations.
I created a dummy pbix here.
Assuming Employee Violations is already defined, the Function Violations measure I created looks like this:
Function Violations = CALCULATE ( [Employee Violations], VALUES ( Employees[Function] ), ALL ( Employees ) )
I would also recommend you remove the Name column from the Violations table as it's not needed.
Regards,
Owen
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
14 | |
10 | |
10 | |
9 | |
9 |
User | Count |
---|---|
20 | |
13 | |
12 | |
11 | |
8 |