Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
I would like to sort a legend by value in a clustered bar chart. Is there any way I can do it. So, I have regions on X-axis and value on y-axis. On X-axis, rigions consist of 6 type of taxes. When I sort the chart by value, it is sorting total tax value. I also would like to sort inside of the rigions the type of taxes by value. Is it possible? Thank you
Create a rank column
rank = RANKX(FILTER(ALL(Sheet3),[region]=EARLIER(Sheet3[region])),[value],,ASC)
Then select the clustered bar chart, click on the "taxes" column on the right pane, then select "Sort vy column"->"Rank"
Best Regards
Maggie
Maggie, @v-juanli-msftThank you for the answer When I created a rank column and sorted by rank it said that it is impposible to sort because In rank column cannot be more than one value of the same value in taxes. My data consist of 17 000 rows and have 7 levels of hierarchy. What kind of information you need to get full understanding of the data in order to check the possible solution. Thank you
my previous test use some specific data, it seems ok with this method, but when the data changes, it is impossible to sort the legend by another column.
Since legend could only sort by one kind order, but waht you want is to sort each legend inside the Axis differently, i'm afraid it is impossible by design.
Best Regards
Maggie