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

Next up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. 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
April Power BI Update Carousel

Power BI Monthly Update - April 2026

Check out the April 2026 Power BI update to learn about new features.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

FabCon and SQLCon Highlights Carousel

FabCon &SQLCon Highlights

Experience the highlights from FabCon & SQLCon, available live and on-demand starting April 14th.