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

Sorting by month name in chronolgocial order in a slicer

I know that you can sort by month name (January, February, March...) in chronological order on a chart using the month numbers, but how can you do this in a slicer? I've done it before using Month & Year combinations, but now I only want the months. 

 

By default the slicer does not recognize it as a date and puts them in alphabetic order, but is there a way so that they sort the months in chronoligcal order?

 

Thanks!

-Dan

1 ACCEPTED SOLUTION
8 REPLIES 8
greggyb
Resident Rockstar
Resident Rockstar

I am super new to Power BI and I need some help applying this to a date situation.

I've got a [Created date] column that I'm adding to the X Axis of charts. The same problem exists for me as has been mentioned here: If I'm displaying months, they appear in the monthly order, but should appear yearly - then monthly.

For example November (2015), December (2015), January(2016), etc.

They currently appear: January (2016), February, November(2015), December(2015),

The values in the field relflect the month and year, but the chart seems to ignore the year.

I would love some specific instruction on how to apply the Sort by Column information. Should I be creating another column and adding order information which corresponds to the [Created Date] column?

 

Any help would be greatly appreciated. Thank you!

@Catalizt Yep, you want a YYYYMM column to sort that field on. That will straighten out your dates.


Looking for more Power BI tips, tricks & tools? Check out PowerBI.tips the site I co-own with Mike Carlo. Also, if you are near SE WI? Join our PUG Milwaukee Brew City PUG

Thanks so much! I'll give it a try!

djnww
Impactful Individual
Impactful Individual

The suggestions above will definitely work.

Hi,

 

I'm experiencing a similar issue as the original post. I have a table with a column 'Month' that contains the text of the month "January","February",... and a column 'Month Number' with a number for the month 1,2,..

I need to show months is a slicer in chronogical sort but is showing alphabetically, the problem is that the slicer doesn't allows more than one field therefore the elipsis in my slicer doesn't shows the 'Month Number' column as a choice to sort by. Am I missing something?

Capture.JPG

 

J0
Regular Visitor

This link helped me with this issue:

https://blog.crossjoin.co.uk/2015/12/15/power-bi-desktop-sort-by-column-and-dax-calculations-that-us...

 

 

If you have month name columns and month number columns in your table, here's what you need to do:

- go to your data table

-select the appropriate table

-highlight the month name column

-on the menu, select the option to 'sort by column' and select the month number column. 

 

When you create a slicer using your month name column, it should be in the month number order. 

You the real MVP!

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.