cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Sorting by Month as Text (Jan Feb Mar etc)

 

I notice in the Power BI Service we still can't sort a chart by another field.

 

This is annoying.  A workaround I found is to add a calculated column with a period as prefix to the month. 

 

=FORMAT([Period],"00")&"-"&[MonthName]

 

3 REPLIES 3
mihart
Microsoft
Microsoft

Go to Power BI Desktop

If you don't already have a month number column, add one.

Select the column containing the month names

Select Modeling tab > Sort By Column and from dropdown select the column that has the month numbers.

Now when you publish to PBI Service, sorting will work correctly.

 

HTH,

Michele

 

 

 

Anonymous
Not applicable

Quick update on this.  I found a column property setting in Analysis Services tabular enables me to specify a sort column.

 

With Power BI Desktop the charts automatically sorted using this property.  

 

I'm just waiting for model changes to be pushed to the service to see if the online chart sorts.

 

 

You should be able to use another column to sort by.  It is hidden in the column properties. You select sort by, then choose another column. I have, in the past, used the month number column to sort my month name column.





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

Proud to be a Super User!




Helpful resources

Announcements
May 2023 update

Power BI May 2023 Update

Find out more about the May 2023 update.

Submit your Data Story

Data Stories Gallery

Share your Data Story with the Community in the Data Stories Gallery.

Top Solution Authors
Top Kudoed Authors