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

The ultimate Microsoft Fabric, Power BI, Azure AI & SQL learning event! Join us in Las Vegas from March 26-28, 2024. Use code MSCUST for a $100 discount. Register Now

Reply
Ski900
Helper II
Helper II

Unable to sort Month Year (text) descending in slicer using Month Sort column

I created a Month Year column and sort it by a custom Month Sort column. It works for sorting ascending, but when I sort it descending it only works in the Data view. When I put either Month Year or Month Sort into a slicer, or table, they do not sort descending. Any help is much appreciated!

 

Month Year                        Month Sort                

December 2017                  201712

January 2018                      201801

February 2018                    201802

 

 

Edit: To be clear, when I vew the data in the table format I can sort in descending order. It's only when I populate a slicer, or table visual, that it stays in ascending order. 

1 ACCEPTED SOLUTION
v-chuncz-msft
Community Support
Community Support

@Ski900,

 

On any visual, select the ellipses menu (...) in the upper right corner and then select the field by which you want to sort.

https://docs.microsoft.com/en-us/power-bi/desktop-sort-by-column

Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

8 REPLIES 8
v-chuncz-msft
Community Support
Community Support

@Ski900,

 

On any visual, select the ellipses menu (...) in the upper right corner and then select the field by which you want to sort.

https://docs.microsoft.com/en-us/power-bi/desktop-sort-by-column

Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Yeah, I'm a tool sometimes. When it's not clicked its that light gray color that looks like it's not available. I assumed that because I had done a custom sort using another column, that is why it was grayed out. But, it wasn't actually grayed out. Once I clicked it, it sorted properly. 

BKirsch12
Resolver II
Resolver II

Did you use the modeling sort by column option?

 

Select Month Year, then Sort by Month Sort.

 

MonthSort.png

I am able to do this as well, but it does not trasnlate to the slicer, that is where my issue is. 

Anonymous
Not applicable

Do the first column is stored as date column in DB? How are you deriving the YYYYMM, what data type it is?

 

Thanks

Raj

MonthSort = 'Calendar'[Year]  & right("0" & month('Calendar'[Date]),2)

 

 

This is then turned into a whole number

Can you attach your file, I can't replicate that error on mine.

Unfortunately I cannot because of the high amount of sensitive data. You're able to have the Month Year sorted in descending order in the slicer?

Helpful resources

Announcements
Fabric Community Conference

Microsoft Fabric Community Conference

Join us at our first-ever Microsoft Fabric Community Conference, March 26-28, 2024 in Las Vegas with 100+ sessions by community experts and Microsoft engineering.

February 2024 Update Carousel

Power BI Monthly Update - February 2024

Check out the February 2024 Power BI update to learn about new features.

Fabric Career Hub

Microsoft Fabric Career Hub

Explore career paths and learn resources in Fabric.

Fabric Partner Community

Microsoft Fabric Partner Community

Engage with the Fabric engineering team, hear of product updates, business opportunities, and resources in the Fabric Partner Community.

Top Solution Authors