Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
In this line and stacked column chart I want the red bar to be on top of the green one, is there a way to do that?
Solved! Go to Solution.
Hi @alex4597 ,
First go to query editor,then add column> columns from example to add a column as below:
#"Added Conditional Column" = Table.AddColumn(#"Changed Type", "Custom", each if [Color] = "red" then 2 else if [Color] = "green" then 1 else null, type number)
Then back to data view>select column color>sort by column;
And you will see:
For the sample .pbix file,pls see attached.
Best Regards,
Kelly
Did I answer your question? Mark my post as a solution!
Hi @alex4597 ,
First go to query editor,then add column> columns from example to add a column as below:
#"Added Conditional Column" = Table.AddColumn(#"Changed Type", "Custom", each if [Color] = "red" then 2 else if [Color] = "green" then 1 else null, type number)
Then back to data view>select column color>sort by column;
And you will see:
For the sample .pbix file,pls see attached.
Best Regards,
Kelly
Did I answer your question? Mark my post as a solution!
@alex4597 You can do this by creating an another table like below and then link it to main table using color column.
Then you can do the sorting using the newly created column like below and have your chart legend in your desired sequence
Proud to be a Super User!
@alex4597 , Change the color from data Color.
Or Create a new sort column the current legend that will reverse the sort order and mark that as the sort column
https://docs.microsoft.com/en-us/power-bi/desktop-sort-by-column
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
114 | |
100 | |
81 | |
70 | |
62 |
User | Count |
---|---|
148 | |
116 | |
104 | |
90 | |
65 |