How to order months chronologically in Power BI

Change from sorting months Apr, Aug, Dec to Jan, Feb, Mar:

This method creates a separate month table and brings it into Power BI to order months chronologically.

I have a video on my YouTube channel explaining this method or you can use this easy-to-follow guide:

Create and save a month table like the one below, it can be in any format,
Here’s a ready made file in excel you can use to save you time typing out the month names!

First column contains the month name as it appears in your data
Second column is a number indicating the order the months should be sorted in
(so for financial year order April would be numbered 1)

Load the table into Power BI using the ‘Get Data’ button

Next you need to sort the month column in this new month lookup table:
1. navigate to the month table in the data tab
1. select the month column
2. go to the ‘sort column’ in the ‘column tools’ tab
3. select ‘month numb’ from the drop down list

Next set up a relationship join between the month lookup and the table containing the monthly data:
1. click on the ‘Manage relationships’ button in the ‘Home’ tab
2. click on ‘New’ to set up a new relationship
3. from the first drop down select the month look up table
4. from the second drop down select the table containing monthly data
5. highlight the columns in each table that contain the month names
6. OK

Now create your visual using the month name from the month look up table, instead of the month name column in your data table, and your months will be ordered chronologically, like this:

Success! You're on the list.

Cover photo by Glen Carrie on Unsplash


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: