Forum Discussion
GemcoDesigns
6 years agoNew Member
Month Sorting
I have create one report( Purchase Monthwise.. But the months are not sorting... and it lokks like as per the image. Can any one help me to overcome this:)..
Anonymous
6 years agoNot applicable
This is how I had to fix my visual with a similar issue. It wouldn't let me sort using my Date values for whatever reason so I wrote this and sorted that by my Date columns
Month Order =
var num = MONTH('TableName'[DateColumn])
return
IF(num = 1, "January",
IF(num = 2, "February",
IF(num = 3, "March",
IF(num = 4, "April",
IF(num = 5, "May",
IF(num = 6, "June",
IF(num = 7, "July",
IF(num = 8, "August",
IF(num = 9, "September",
IF(num = 10, "October",
IF(num = 11, "November",
IF(num = 12, "December"
))))))))))))