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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
ShreyasK
Frequent Visitor

How to custom sort x axis in bar chart

I have bar chart which shows floor wise cout of employees. I wanted to sort visual by floor sequence like - Basement, Ground Floor, 1st Floor and then 2nd Floor (Left to right) but since floor names contains number & alphabets I am not able to sort it in required sequence. When I sort axis by floor ascending order then bar chart looks like below -

 

Current sequence.png

 

 

 

 

 

 

 

I want to see in this sequence - Basement - Ground Floor - 1st Floor - 2nd Floor.

 

I tried by creating Floor table with Sr.No and merged it with my orginal database table but still not getting the required result.
Floor tableFloor table

 

 

 

 

 

 

Can anyone suggest, How this can be achieved..?

1 ACCEPTED SOLUTION
PaulDBrown
Community Champion
Community Champion

You need to sort the Floor column by the sort order column in the table view

Sort.gif

 

Then sort the axis in the visual by Floor in ascending order

sort axis.gif

 

 





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.






View solution in original post

2 REPLIES 2
ShreyasK
Frequent Visitor

@PaulDBrown - Thank you very much..!!! This worked perfectly 😊

 

Screenshot 2022-10-09 143729.png

PaulDBrown
Community Champion
Community Champion

You need to sort the Floor column by the sort order column in the table view

Sort.gif

 

Then sort the axis in the visual by Floor in ascending order

sort axis.gif

 

 





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
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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