Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
I have my data in excel with month name in one of the columns. When I create a chart and sort by month, it sorts december before January since it bring the data as text. How can I fix this issue? I tried to convert the data into date type in Power BI but it gives me an error that that data can not be changed.
Solved! Go to Solution.
Hi @anilbatra,
I would suggest going into the Query Editor and creating a Conditional Column.
For your Conditional Column you would create it where for each Month you would give it a number.
As shown below:
And then once this loads into Excel or Power BI Desktop, click on the Modelling tab, and where it says Sort by Column, click on the Drop Down and select the Month Number column you created above.
After which your months should then sort correctly.
You have to select the field on the fields list, not in the visuals pane.
Hi @anilbatra,
I would suggest going into the Query Editor and creating a Conditional Column.
For your Conditional Column you would create it where for each Month you would give it a number.
As shown below:
And then once this loads into Excel or Power BI Desktop, click on the Modelling tab, and where it says Sort by Column, click on the Drop Down and select the Month Number column you created above.
After which your months should then sort correctly.
I created the conditional column as you instructed. I went to the modeling tab to do my sort and the "sort by column" button is greyed out. Any suggestions?
Hi @naperryman,
What you will need to do is to select the Month column so that it is shown as selected with the yellow bar around it as shown below.
Once you have selected the above, the Sort By Column should then be able to be changed.
The chart, a bar graph, does not let me sort it by this conditional column. The only options available are the month name (used in x-axis) and various values I used in chart. The top menu option "Sort by Column" is grayed out.
You have to select the field on the fields list, not in the visuals pane.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
79 | |
78 | |
59 | |
36 | |
33 |
User | Count |
---|---|
94 | |
61 | |
56 | |
49 | |
41 |