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.
I have a report that will display the highest labor time for each category. I also want to be able to display the employee name associated with that entry.
What I am hoping for is a visual similar to the middle one on the bottom that shows each category and then shows the employee name that coresponds to the highest labor entry for each filtered category. I dont really care if the visual is a table or a graph as long as I can display the category and a name.
Here is a link to my pbix file:
Solved! Go to Solution.
HI @cmccully ,
Create a measure like below to get the employee name whose labor hour is highest among rest.
HI @cmccully ,
Create a measure like below to get the employee name whose labor hour is highest among rest.
That worked perfectly, thank you!
Can you walk me through the DAX expression? I am trying to learn but still find DAX pretty confusing.
Hi @cmccully ,
Top Employee = MAXX(TOPN(1,VALUES(Query1[EMPLOYEE_NAME]),CALCULATE(Sum(Query1[LABOR_HOURS])),DESC),Query1[EMPLOYEE_NAME])
Basically TOPN function is used to give to top N rows from specified table. In your scenario I put 1 as a first parameter of TOPN so it will return top 1 value of emplyee whose labor hour is highest among rest employee.
TOPN function basically return result in the form of table so put this into MAXX function as a first parameter cause it will iterate thorugh the entire table and return the value specfied in second parameter of MAXX i.e. Employee name.
I will really appreciate your KUDOS for support!
Thanks!
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 |
---|---|
112 | |
97 | |
85 | |
67 | |
59 |
User | Count |
---|---|
150 | |
120 | |
100 | |
87 | |
68 |