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

DAX rolling 12 month sorting issue

Hi there,

I am trying to create a rolling 12 months visual here:

 

salgouda_0-1693430193534.png

 

 

but the sorting options are either by the turnover rate (which misses with the month order) or by the month number (which sorts past 12 months from jan to dec)

since this is the order that I need
Aug 1
Jul 2
June 3
May 4
April 5
Mar 6
Feb 7
Jan 8
Dec 9
Nov 10
Oct 9
sep 8

and I need this order to shift monthly according to each month

I created this calculated column

 

salgouda_1-1693430273118.png

 

 

but it clearly evaluates to blank for months sep, oct, nov, dec where months evaluate to (0,-1,-2,-3)

how can I work around this to get the right sort order for my visual?

Thanks in Advance!

4 REPLIES 4
technolog
Super User
Super User

I hope this message finds you well. I've noticed that this solution remain unresolved. If any of you have managed to find a resolution to the issue, I kindly request that you share your solution for the benefit of the entire community. Alternatively, if you're still facing challenges, please do let us know as well.

Your insights and updates will greatly assist others who might be encountering the same challenge.

@technolog what's the purpose of your message?  Please try to limit your contribution to either asking a clarifying question or providing a solution proposal (or - worst case - a personal opinion).

@salgouda If you haven't solved your problem, please try
https://blog.enterprisedna.co/sorting-date-table-columns-in-power-bi/

 

@lbendlinThank you for taking the time to respond. I understand the importance of clarity in our communications. My message stemmed from an observation that several solutions within our community have answers but they haven't been accepted or marked as resolved. This could possibly be because some contributors might have forgotten to provide feedback on the final outcome, leaving topics unresolved. My goal is to ensure that no solution remains in such a state.

I deeply wish for our community to remain vibrant and active. Abandoned solutions can give the impression of indifference. I'd like to emphasize the importance of feedback. When members, especially esteemed ones like yourself, take time out of their day to offer assistance, it's invaluable to receive updates or acknowledgment of proposed solutions. This not only recognizes the efforts of those trying to help but also builds a repository of resolved queries. The more feedback and results we share, the fewer repetitive questions we'll have, as most of them would have existing solutions to refer to.

Again, thank you for your guidance. I'll aim for more direct and concise communications in the future, keeping the betterment of our community at heart.

lbendlin
Super User
Super User

Use a YearMonth column for sorting.

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