Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi, I have the below measure to count the number of records in the table "Employee Vote" where
the Role is indicated as Sales and the Region is Europe.
Count Europe Sales Votes =
CALCULATE(COUNTROWS('Employee Vote'), FILTER(FILTER('Employee Vote', Employee Vote[Role]="Sales"), 'Employee Vote'[Region]="Europe"))
Additionally, I would like to count only distinct records by an "Employee Name" column in the same table. How can I modify the syntax to achieve this? Thank you.
Solved! Go to Solution.
Hi,
Please try the below whether it suits your requirement.
Count Europe Sales Name =
CALCULATE (
COUNTROWS ( DISTINCT ( 'Employee Vote'[Employee Name] ) ),
FILTER (
'Employee Vote',
'Employee Vote'[Role] = "Sales"
&& 'Employee Vote'[Region] = "Europe"
)
)
If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.
Hi,
Please try the below whether it suits your requirement.
Count Europe Sales Name =
CALCULATE (
COUNTROWS ( DISTINCT ( 'Employee Vote'[Employee Name] ) ),
FILTER (
'Employee Vote',
'Employee Vote'[Role] = "Sales"
&& 'Employee Vote'[Region] = "Europe"
)
)
If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.
Thanks very much, this works fine.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
111 | |
95 | |
80 | |
68 | |
59 |
User | Count |
---|---|
150 | |
119 | |
104 | |
87 | |
67 |