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

Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!

Reply
David_Efr
Regular Visitor

Displaying rank affected by slicer

Hi,

 

I'd like to create a dashboard with a few slicers that filter the visuals.

However, I'd also like to display a text that shows me the rank of the group selected in the slicer among the general population.

 

Example

 

Suppose I have this data: 3 columns from the data source and an additional calculated measure

CompanyShare priceEPSPE Ratio (calculated: [Share price] / [EPS])
Intel52.434.4311.84
IBM139.449.5014.68
Oracle55.412.7919.86

 

I have a single-selection slicer that selects the company.

Suppose I have "Intel" selected in the slicer.

Then, I'd like to have text that says "Rank: 1 out of 3".

If I change selection to "Oracle", I'd like to have the text change to "Rank: 3 out of 3".

 

My question here is how can I neutralize the slicer's effect on the grand total?

I'd like to show the "count(distinct company)" (in SQL terms) calculated on the entire population, and a similar consideration applies on the ranking.

 

I suppose there's a DAX solution, but I'm not too familiar with it yet...

 

Thanks,

David

3 REPLIES 3
v-yuta-msft
Community Support
Community Support

@David_Efr ,

 

You can create a calculate column using DAX below:

Rank =
RANKX ( Table, [PE Ratio],, desc, DENSE )

Community Support Team _ Jimmy Tao

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

v-yuta-msft
Community Support
Community Support

@David_Efr ,

 

Suppose I have this data: 3 columns from the data source and an additional calculated measure

Company Share price EPS PE Ratio (calculated: [Share price] / [EPS])
Intel 52.43 4.43 11.84
IBM 139.44 9.50 14.68
Oracle 55.41 2.79 19.86

 

I have a single-selection slicer that selects the company.

Suppose I have "Intel" selected in the slicer.

Then, I'd like to have text that says "Rank: 1 out of 3".

If I change selection to "Oracle", I'd like to have the text change to "Rank: 3 out of 3".

 

My question here is how can I neutralize the slicer's effect on the grand total?

I'd like to show the "count(distinct company)" (in SQL terms) calculated on the entire population, and a similar consideration applies on the ranking.


In this example, which column do you want to implement the rank measure on? Where is the population field?

 

Community Support Team _ Jimmy Tao

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

I'd like to display the rank of Company by 'PE Ratio' column.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

Vote for your favorite vizzies from the Power BI World Championship submissions!

Sticker Challenge 2026 Carousel

Join our Community Sticker Challenge 2026

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.