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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
sheva
Frequent Visitor

Weekly order

Hi,

 

I have format weeks by " YYYY-MM" and now week 10 is causing problems. Order was just fine beore week 10: 2019-1, 2019-2, 2019-3... and now order is 2019-10, 2019-1, 2019-2, 2019-3...

 

Any help?

2 ACCEPTED SOLUTIONS
PattemManohar
Community Champion
Community Champion

@sheva  Please add an another column as "SortKey" and use this as "Sort By Column" for the "WeekNum" field

 

SortKey = FORMAT([Date],"YYYYWW")

image.pngBefore using SortKeyBefore using SortKeyAfter using SortKeyAfter using SortKey

 





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

Proud to be a PBI Community Champion




View solution in original post

@sheva Yes, you need to change the Data Type of sortkey (which is our calculated column) to "Whole Number"





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

Proud to be a PBI Community Champion




View solution in original post

5 REPLIES 5
PattemManohar
Community Champion
Community Champion

@sheva  Please add an another column as "SortKey" and use this as "Sort By Column" for the "WeekNum" field

 

SortKey = FORMAT([Date],"YYYYWW")

image.pngBefore using SortKeyBefore using SortKeyAfter using SortKeyAfter using SortKey

 





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

Proud to be a PBI Community Champion




weekorder.JPGweekl.JPG

 

@PattemManohar Didn't get that working. Sould the type be text or number?

On the list order is as I want, but not in the graph.

@sheva Yes, you need to change the Data Type of sortkey (which is our calculated column) to "Whole Number"





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

Proud to be a PBI Community Champion




It fixed first problem but made a second with visualization. I use that YYYY-MM format as filter.

 

virhe.JPG

sheva
Frequent Visitor

@PattemManoharFor some reason it's working now, when I try it second time.:)

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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