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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
Elisa112
Helper V
Helper V

Sort dates in month order for bar chart visual

Hi Experts 

I am trying to sort my visual into the correct month order (ascending by month).  I have data from Sept 2023 onwards. The 2023 months are in the correct order however not for 2024. See below

Elisa112_0-1715247644138.png

I'm probably missing something very simple, any advice greatly received.

thanks in advance

 

1 ACCEPTED SOLUTION
miTutorials
Super User
Super User

6 REPLIES 6
miTutorials
Super User
Super User

Watch this short tutorial to sort months on the Column chart.

 

How to Sort Months the right way in PowerBI | Bar Chart | MI Tutorial - YouTube

Thank you @miTutorials 

PhilipTreacy
Super User
Super User

Hi @Elisa112 

 

Download example PBIX file

 

I suspect your 'date/month' column is actually text and in your chart it is sorting alphabetically in descending order S -> A

 

You need to use a proper date column like this

 

datecols.png

 

The data will then sort correctly

 

datecols2.png

 

Phil



Did I answer your question? Then please mark my post as the solution.
If I helped you, click on the Thumbs Up to give Kudos.


Blog :: YouTube Channel :: Connect on Linkedin


Proud to be a Super User!


Hi @PhilipTreacy 

thanks for your assistance, my tables looks like this:

Elisa112_0-1715256748273.png

Elisa112_2-1715257088617.pngElisa112_3-1715257130812.png

 

 

I also have a customer table with dates such as (referral date, start date). So I created a measure to calculate the total customers but the visual shows the months in the wrongorder. I have tried creating a sorting column on my customer table but I get the following error when I try this solution

 

Elisa112_1-1715257038709.png

 

Any further help much appreciated.

Elisa112

 

 

 

fahadqadir3
Super User
Super User

@Elisa112 You can sort the months by using the following calculated column:

Sorting Condition = - ( YEAR('Table'[Date])*100+MONTH('Table'[Date]) )

Screenshot_5.png

Sort the month by sorting condition:

Sorted by.png

Power BI file attached:

Sorting.pbix

 

Regards,

Fahad Qadir

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

Gabry
Super User
Super User

Hello,

what columnd did you put on the x axis? Like month? You have to sort that column by date.

If it's a column from the calendar table.

You go in the dataview, then select the month column, than select order by date, if you can't order by date you need a month number column and then you sort by month number. Hope I made my point

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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