Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

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.

Reply
setis
Post Partisan
Post Partisan

Top performer per case

Dear all


I have a list op activities and I'm trying to identify the user with most activities per case. If there are 2 users with the same top nr of activities, they can share the top. 

 

I need this on a calculated column on the table. 

This is an example of the table and the expected result:

 

TypeCaseUserExpected
Email111A1
Email111A1
Email111B2
Email111C2
Email111D2
Email111A1
Email122A2
Email122B1
Email122B1
Email122C2
Email122D2

 

Thank you in advance!

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@setis , Create two columns like

 

Activity = countx(filter(table,[Case] =earlier([Case] && [User] =earlier([User] )),[User])


rank = rankx(filter(table,[Case] =earlier([Case])),[Activity],,desc,dense)

 

For Rank Refer
https://radacad.com/how-to-use-rankx-in-dax-part-1-of-3-calculated-columns

View solution in original post

2 REPLIES 2
setis
Post Partisan
Post Partisan

@amitchandak thanks a lot, this is what I was looking for. 

amitchandak
Super User
Super User

@setis , Create two columns like

 

Activity = countx(filter(table,[Case] =earlier([Case] && [User] =earlier([User] )),[User])


rank = rankx(filter(table,[Case] =earlier([Case])),[Activity],,desc,dense)

 

For Rank Refer
https://radacad.com/how-to-use-rankx-in-dax-part-1-of-3-calculated-columns

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors