Starting December 3, join live sessions with database experts and the Microsoft product team to learn just how easy it is to get started
Learn moreShape the future of the Fabric Community! Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions. Take survey.
I am trying to sort a column called MOnth Year Num. How can I create a column to sort it?
I have a Bar chart that shows the last 3 months. So I want to sort that column so that October 2022 comes fast.
Solved! Go to Solution.
Hi,
One of ways to create a sort column for the Month Year Num column is to create a ENDOFMONTH column by using a DATE column and EOMONTH DAX formula.
EOMONTH function (DAX) - DAX | Microsoft Learn
I hope this helps.
If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.
@Datagulf,
you can create a Date_start column as below.
then create a copy of the "month year num" column and use the Date_start column to sort. We create the copy of the column to ensure that you wont get the circular dependancy error.
then use the newly created copy of the column in your chart as below.
Can we get more info on how you're trying to sort it? I can see you've made a sort column.
Can you select the sort column from here?
Thanks, I am looking for sth different, which is to sort a Month Year Num. Your Solutions is for a fiscal year.
I have a Bar chart that shows the last 3 months. So I want to sort that column so that October 2022 comes fast
Create a Month number + Year column
Year('Date') & Month(date).
Put this column in the Tooltip part of your visual
Then in the top right of your visual, sort by that column
Hope this helps!
It has ordered but not correctly...
2023 Jan comes at the right position but 2022 months are not ordered...
Can you show me your calculated Column code for the sort please? 🙂
Month and Year = FORMAT([Date], "YYYY") & FORMAT('Calendar'[Date],"mmmm")
or try YEAR('Calendar'[Date] & MONTH('Calendar'[Date])
this is how i would write it 🙂
Hi,
One of ways to create a sort column for the Month Year Num column is to create a ENDOFMONTH column by using a DATE column and EOMONTH DAX formula.
EOMONTH function (DAX) - DAX | Microsoft Learn
I hope this helps.
If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.
Please expound, I did not understand your solution..
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Check out the November 2024 Power BI update to learn about new features.
User | Count |
---|---|
93 | |
88 | |
83 | |
76 | |
49 |
User | Count |
---|---|
145 | |
140 | |
109 | |
68 | |
55 |