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
AbdullahTammour
Frequent Visitor

not able to sort by months in chronological order

Hello All,

I have an Excel table with a date column and the next column contains this formula

 

=TEXT(B222,"MMMM")

 

which as you know extracts the month name from the date cell.

 

when I use Excel to make some data analysis: Excel recognizes that the column contains a month name so when I create a chart or a slicer it sorts the months chronologically (January, February, March, ,...) 

 

When I tried to use Power BI to create a chart for the same table, Power BI doesn't recognize that the column contains month names and it sorts them alphabetecally (April, February, January,....) or sometimes in unlogical order.

 

Untitled.png

 

is there a solution for this?

Many thanks in advance.

 

2 ACCEPTED SOLUTIONS
TomMartens
Super User
Super User

Hey,

 

you have to order the column with the month names by a column that contain 1 for January, 2 for February and so on

 

maybe this will get you startet

https://community.powerbi.com/t5/Desktop/Month-Name-in-sorting-order/m-p/152006/highlight/true#M6575...

 

You alsoi may try the search "Month" and "Order"

 

Hope this helps

 

 



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

View solution in original post

v-ljerr-msft
Employee
Employee

Hi @AbdullahTammour,

 

Have you tried the solution provided by @TomMartens above? It should work in your scenario.

 

 

If it works, Could you accept it as solution to close this thread? If you still have any question on this issue, feel free to post here. Smiley Happy

 

Regards

View solution in original post

2 REPLIES 2
v-ljerr-msft
Employee
Employee

Hi @AbdullahTammour,

 

Have you tried the solution provided by @TomMartens above? It should work in your scenario.

 

 

If it works, Could you accept it as solution to close this thread? If you still have any question on this issue, feel free to post here. Smiley Happy

 

Regards

TomMartens
Super User
Super User

Hey,

 

you have to order the column with the month names by a column that contain 1 for January, 2 for February and so on

 

maybe this will get you startet

https://community.powerbi.com/t5/Desktop/Month-Name-in-sorting-order/m-p/152006/highlight/true#M6575...

 

You alsoi may try the search "Month" and "Order"

 

Hope this helps

 

 



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

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.