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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Anonymous
Not applicable

Dynamic Top N when using Dynamic Legend?

I currently have a stacked bar chart visual that I'm trying to apply Top N to. This in itself is pretty simple, as all I would have to do is create the what-IF parameter and use RANKX() in the displayed measure. However, I have also applied another technique, detailed in this video by Guy in a Cube: https://www.youtube.com/watch?v=jcxJzh1TYWg, to create a dynamic Legend. So, I can choose to show my Legend by Business Sector, Business Division, and Business Segment.

 

How do I create a Top N with a dynamic maximum amount? I have 10 Business Sectors, 25 Business Divisions, and 40 Business Segments. When I create the what-If Top N parameter, I only have the option to set a fixed minimum and maximum. I would like the Top N range to be 0-10 if the user selects Business Sector as the legend, 0-25 if they select Business Division, and 0-40 if they select Business Segement. Is this possible?

0 REPLIES 0

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 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.