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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
Alisea_MI
Advocate III
Advocate III

Sort a dynamic text column (Month Year)

Hi!

I have a dynamic text column containing Month + Year (6 previous moths data).
The column is current being sorted as text by month name.
  
How can I sort it by Year - Month? I have no other date column to sort it by.

 

Many thanks in advance!

 

Capture.JPG

 

 

1 ACCEPTED SOLUTION
ribisht17
Super User
Super User

@Alisea_MI 

 

Step 1

Create a duplicate column

 

Step 2

Replace Mars with Mar, Februari with Feb so on

 

Now you get a date column with Step 2, now sort on this

 

Regards,

Ritesh

View solution in original post

4 REPLIES 4
ribisht17
Super User
Super User

@Alisea_MI 

 

Step 1

Create a duplicate column

 

Step 2

Replace Mars with Mar, Februari with Feb so on

 

Now you get a date column with Step 2, now sort on this

 

Regards,

Ritesh

Arul
Super User
Super User

@Alisea_MI ,

try to create one calculated column using beolw dax,

Monthyear sort = FORMAT(financials[Date],"YYYYMM")

and then sort the above column by using sortby column option.

Thanks,

Arul





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!


LinkedIn


ribisht17
Super User
Super User

@Alisea_MI 

 

An elegant solution is to create a date bin. You do this by

 

  1. Right click on data field (make sure it's a date type)
  2. Select 'New Group'
  3. Create Bins (could be more than one month if you wish)
  4. choose the new bin for your 'shared axis' in the Report View
  5. win

ribisht17_0-1652862741857.png

>>>> how to sort Date (MonthYear column)? - Microsoft Power BI Community

 

Regards,

Ritesh

Hi, @ribisht17 ! Thanks for you idea! Unfortunately I could change it to a date - the months are in Swedish and it didn't work.

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

Find out what's new and trending in the Fabric Community.