Forum Discussion
How do I custom sort columns within a cluster bar chart?
- 5 years ago
Hi, trinas
Could you please tell me whether your problem has been solved?For now, there is no content of description in the thread.
As mentioned by sjrrkb123 , what you need is to sort the column 'phase' by column 'Pos' in 'column tools' . And the feature is available in 'data tab' rather than in 'report tab'.
Before:
After:
Please check my sample pbix file for more details.
Best Regards,
Community Support Team _ Eason
trinas I had this problem myself....I was not able to make the sorting dynamic but rather created a sort key in power query for your "Phase" column.
-it would be a custom column that says if [Phase] = "50% DD" then 1 else if [Phase] = "100% DD" then 2 else 3 end
-Note, this can be done using the conditional column option as well in Power Query.
Then, sort the column by the sort key using the "Sort By Column" option when selecting your column and looking that column tools in Power BI Desktop.
Just a reminder, this will not be dynamic based on the $$ values
****EDIT: I looks like POS already is a sort key for you. I think you can skip the Power Query step and just use the sort column tool I put in the screenshot.
The "Column tools" and "Table tools tabs at the top don't show up for me - I only get "Format" and "Data/Drill"
- sjrrkb1235 years ago
Helper III
trinas this is because you have selected the visual and then gone to the editor bar at the top. Rather, you need to select the table with this column in it and then go to the editor bar.
Below is when the visual is selected and only format & data/drill is available:
Note the difference now when I select on a table with the appropriate column selected:
In your case, select your table the click on the "Phase" column then go to column tools, click sort by column & choose POS.
- trinas5 years agoRegular Visitor
Gotcha - i don't have the table shown on the dashboard, only the visual. I tried going to the data section to sort it from there but it doesn't appear that that option is available there, only if I put the table in the actual dashboard?
- sjrrkb1235 years ago
Helper III
Can you provide a screenshot of what you see?
Also, have you updated to the latest version of PBI (February 2021 release is newest I think)
- Anonymous2 years agoNot applicable
yes I have the latest version