Forum Discussion
Date Slider Not Handling Years Correctly
I'm making a report where every visual is filtered by a date slider at the top of the page.
It used to function properly, but now it will disregard the year and order the months in chronological order.
Exmaple: The slider is a date range from November 2018 - March 2019.
The charts are listed in the following order:
January 2019
February 2019
March 2019
November 2018
December 2018
12 Replies
- parry2kSuper User
Anonymous do you have sort order on chat to z->a instead of a->z, click on dots on top right corner of the chart and check the sort order.
- AnonymousNot applicable
Regardless of A>Z vs. Z>A, it displays incorrectly.
A>Z it appears as follows:
January 2019February 2019
March 2019
November 2018
December 2018
Z>A it appears as follows:
December 2018November 2018
March 2019
February 2019
January 2019
Power BI is not correctly recognizing the year.
- parry2kSuper User
Anonymous by default it sorting alphabatically. You need add another column in your table to sort this month field.
Add following column in your date dimenson, change table name and column name as per your model.
Month Sort = FORMAT( Table[Date], "YYYY-MM" )
Now go to modelling tab, choose your month colum and click sort by column on the menu and select "Month Sort". This will fix the issue.