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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

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
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

Power BI Carousel June 2024

Power BI Monthly Update - June 2024

Check out the June 2024 Power BI update to learn about new features.

PBI_Carousel_NL_June

Fabric Community Update - June 2024

Get the latest Fabric updates from Build 2024, key Skills Challenge voucher deadlines, top blogs, forum posts, and product ideas.

Top Solution Authors