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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Custom sort on x-axis

Hi there,

 

I have spent several hours trying to get my column chart displaying the columns in the right order. I have this chart:

MitSom_0-1647942230508.png

But I need it to sort the x-axis as follows:

Response

Every day
2-3 times a week
Once a week
2-3 times a month
Once a month
Less than once a month
Never

 

I have tried creating a new table with the above, and sorting it by an index, but it is still not working. Any ideas or help would be much appreciated. Thank you so much in advance!

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

Hi, @Anonymous ;

You could transform data then add index column.

vyalanwumsft_0-1648184032246.pngvyalanwumsft_1-1648184063473.png

Then click Response column and sort by Index column.

vyalanwumsft_2-1648184208929.png

Set sort axis.

vyalanwumsft_3-1648184272811.png

The final output is shown below:

vyalanwumsft_4-1648184321439.png


Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

View solution in original post

6 REPLIES 6
MkHurd01
New Member

When I click on the elipsis (three dots ....)  I do not have the option to "Sort By"

Can I add that option in somehow? 
Thanks!

v-yalanwu-msft
Community Support
Community Support

Hi, @Anonymous ;

You could transform data then add index column.

vyalanwumsft_0-1648184032246.pngvyalanwumsft_1-1648184063473.png

Then click Response column and sort by Index column.

vyalanwumsft_2-1648184208929.png

Set sort axis.

vyalanwumsft_3-1648184272811.png

The final output is shown below:

vyalanwumsft_4-1648184321439.png


Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

Thank you for the above. however, my selections in my visuals seem to be different.  Is there something I need to do for it to apear? 

22LACMT_0-1672855663696.png

 

darshaningale
Resolver II
Resolver II

Create a new conditional column "Sort/Order" in powerquery based on x-axis column and use the new column as Sort for x-axis.

darshaningale_0-1647943294152.png

 

 

 

Regards
DI

Did I answer your question? Mark my post as a solution, this will help others!
Kudos are also welcome.

Anonymous
Not applicable

I dont want to sort my master table with a new column, because for another visual, I will need to sort on another column, if that makes sense?

Create a dimension table for the values in the axis and add the sorting order column using SWITCH. Sort the values by the sort order column and then use this field as the axis





Did I answer your question? Mark my post as a solution!
In doing so, you are also helping me. Thank you!

Proud to be a Super User!
Paul on Linkedin.






Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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