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
janisCNH
Frequent Visitor

Ranking Subjects.

Hello Guys!

 

I have a problem with a ranking for a report. The ranking should contain the top 5 issus of a technical support. You can see this data under Subject in the attached picture. Is it possible to rank the count of the subjects?

 

Thanks for any help!

Janis  

 

 SubjectProblem.JPG

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hello @janisCNH

I think the solution explain by @asocorro is good, but you may need something more.

 

If your ranking is used for selected objects (just like slicer for example) you have to replace the ALL keywork by the ALLSELECTED. 

It should recalculate the ranking based only on the selected members.

 

Sebastien

View solution in original post

4 REPLIES 4
janisCNH
Frequent Visitor

Hi!

 

At first, thank you two for the quick answer. The kind community from Power BI really helps to better get into my reporting project!

 

On the attached pictures, you can see my workingsteps. The program says that I did something wrong. Can you explain it to me? I am really not that familiar with Power BI yet.

 

thx!

 

Subject Count.JPGSubject Rank.JPGTable.JPG

Anonymous
Not applicable

Hello @janisCNH

 

you use the UNION keyword, which is made to unifiy two tables with corresponding columns, but, you passed A field with multiples values and a aggregate fields for the second argument.

 

I don't know why you want ton unify this two objects, but, if you want to display them in a table, you don't have to do this, just use the "Subject" field, and the "Subject rank" measure.

 

If this not what you want to do, tell it to me.

 

Sebastien

asocorro
Skilled Sharer
Skilled Sharer

Create a measure [Subject Count] and then rank based on it, with a measure [Subject Rank] =  RANKX(ALL(TableName[Subject]), [Subject Count]).  Create a table with the columns Subject and [Subject Rank].  


As to displaying the top 5, one way is to filter the visual with [Subject Rank] <= 5.

Connect with me in LinkedIn: https://pr.linkedin.com/in/adolfosocorro
Follow me on Twitter: https://twitter.com/AdolfoSocorro
Anonymous
Not applicable

Hello @janisCNH

I think the solution explain by @asocorro is good, but you may need something more.

 

If your ranking is used for selected objects (just like slicer for example) you have to replace the ALL keywork by the ALLSELECTED. 

It should recalculate the ranking based only on the selected members.

 

Sebastien

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.