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

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
mumbetaliyev
Frequent Visitor

Sorting legend by value in clustered bar chart

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

3 REPLIES 3
v-juanli-msft
Community Support
Community Support

Hi @mumbetaliyev

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"

8.png

 

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

Hi @mumbetaliyev

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

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors