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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
Gerri
Frequent Visitor

Sort legend for stacked column chart

I'm trying to sort the legend by a custom order and looked at past tutorials to create the sort table and sort index.

But when I try to sort the legend for the stacked chart, it still sorts the legend by alphabetical order.

Am I missing a step somewhere?

 

Sample data and the stacked chart:

Gerri_0-1655107977168.png

Relationships between the tables:

Gerri_1-1655108089624.png

 

Table sorted by column sort order:

Gerri_2-1655108224475.png

 

1 ACCEPTED SOLUTION
v-jayw-msft
Community Support
Community Support

Hi @Gerri ,

 

Add the sort order column to tooltip field, then you should be able to sort the visual by that column.

 

Best Regards,

Jay

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

View solution in original post

8 REPLIES 8
v-jayw-msft
Community Support
Community Support

Hi @Gerri ,

 

Add the sort order column to tooltip field, then you should be able to sort the visual by that column.

 

Best Regards,

Jay

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

Sorted! Thanks for your help!

Gerri_0-1655426624819.png

 

mohammedadnant
Impactful Individual
Impactful Individual

Hi @Gerri 

 

You need to use the feature of SORT BY COLUMN, pls see below image

mohammedadnant_0-1655117125321.png

 

 

Thanks & Regards,

Mohammed Adnan

Learn Power BI: https://www.youtube.com/c/taik18

Did I answer your question? Mark my post as a solution! Appreciate your Kudos!! !!

Thanks & Regards,
Mohammed Adnan
Learn Power BI: https://www.youtube.com/c/taik18

Hi @mohammedadnant ,

I did use SORT BY COLUMN but it doesn't affect the visual.

Gerri_1-1655167535440.png

 

 

Hi @Gerri 

 

Can you try to select ascending/descending in the legend of this visual

mohammedadnant_0-1655182553682.png

 

 

Thanks & Regards,

Mohammed Adnan

Learn Power BI: https://www.youtube.com/c/taik18

Did I answer your question? Mark my post as a solution! Appreciate your Kudos!! !!

Thanks & Regards,
Mohammed Adnan
Learn Power BI: https://www.youtube.com/c/taik18

Hi @mohammedadnant ,

With the legend of this visual selected:

Gerri_0-1655185205900.png

With the legend of this visual not selected:

Gerri_1-1655185289183.png

The strange thing is that I have no problems with the legend if it was a pie chart..

Gerri_2-1655185520255.png

 

Gerri
Frequent Visitor

Hi @mohammedadnant ,

Is there any solution for the visual to sort by the custom sort order? I've tried rebuilding my visual but the legend won't sort by the custom order if it's a column chart..

Hi @Gerri 

 

Please share the sample to test.

 

Thanks & Regards,

Mohammed Adnan

Did I answer your question? Mark my post as a solution! Appreciate your Kudos!! !!

Thanks & Regards,
Mohammed Adnan
Learn Power BI: https://www.youtube.com/c/taik18

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

November Carousel

Fabric Community Update - November 2024

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

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.