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
Anonymous
Not applicable

Top N Not Working on Percentage

I have a table with contracts, the avg number of employees, and the annualized total turnover. I want to filter it to contracts with 10-15 employees and I want to get the top 10 contracts based on the Annualized Total Turnover (Labeled on the data field as "Avg Vol + Invol TO")

 

When I apply the filter for Top 10, it's showing me much more than 10 results. When I change the filter to Top 5, it shows me no results.

 

 

All of my calculations work properly but I am including them below in case there's a change I need to make in the DAX.

 

Avg Vol+Invol TO = ((((sum('Step 10 - Master Reporting Table'[CNT - Vol Terms])+sum('Step 10 - Master Reporting Table'[CNT - Invol Terms]))/[Avg Active Count])/[Months Count])*12)
 
Avg Active Count = (sum('Step 10 - Master Reporting Table'[CNT - Active Count]))/[Months Count]
 
Months Count = DISTINCTCOUNT('Step 10 - Master Reporting Table'[Reporting Month])
 
The screenshot on the right includes the filters in the "Filters on this visual" section of the menu.
 
[Ignore the part of the screenshot that says "is greater than or equal to 15". That was supposed to be "less than or equal to 15". The problem still exists when I change that.]
 
tempsnip.png.jpg
1 ACCEPTED SOLUTION
v-chuncz-msft
Community Support
Community Support

@Anonymous 

 

You may try RANKX to add a measure, then take advantage of Visual level filters and Show items with no data in Power BI.

 

Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

4 REPLIES 4
v-chuncz-msft
Community Support
Community Support

@Anonymous 

 

You may try RANKX to add a measure, then take advantage of Visual level filters and Show items with no data in Power BI.

 

Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

Thank you @v-chuncz-msft . Sorry for the delay in responding. My manager needed me to focus on another project last week.

 

I tried using the rankx but I must be doing something wrong. See the table below. It is supposed to rank the Annualized Vol TO %

 

[Assume the header below should say "RANK Vol Turnover"]

 

rankx.PNG

 

 

 

 

 

 

 

 

 

 

 

 

 

 

There are my formulas:

 

RANK Vol Turnover = RANKX('Step 10 - Master Reporting Table',[Avg Vol TO],0,DESC,Skip)
 
Avg Vol TO = (((sum('Step 10 - Master Reporting Table'[CNT - Vol Terms])/[Avg Active Count])/[Months Count])*12)
Anonymous
Not applicable

Can anyone help with this? I still have not figured it out.

Anonymous
Not applicable

Does anyone have a solution to this? The tool is not working as expected.

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.