Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

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.

Reply
Bu__
Frequent Visitor

100% stacked bar chart - sort of text column by index with same colors in legend

Hi,

I  want to create a 100 % stacked bar chart which has  data like below

TicketCreatedTime spentstateIndex
id 110/24/2023 16:491P41
id 110/24/2023 17:230P41
id 110/24/2023 17:401P22
id 110/24/2023 18:020P22
id 110/24/2023 18:070P22
id 110/24/2023 18:100P22
id 110/24/2023 18:380P22
id 110/24/2023 18:490P33
id 110/24/2023 18:5013P33
id 110/25/2023 7:130P33
id 110/25/2023 7:180P33
id 110/25/2023 7:211P33
id 110/25/2023 8:200P33
id 210/24/2023 16:491P41
id 210/24/2023 17:230P41
id 210/24/2023 17:401P22
id 210/24/2023 18:020P22
id 210/24/2023 18:070P22
id 210/24/2023 18:100P22
id 210/24/2023 18:380P22
id 210/24/2023 18:490P33
id 210/24/2023 18:5013P33
id 210/25/2023 7:130P33
id 210/25/2023 7:180P33
id 210/25/2023 7:211P33
id 210/25/2023 8:200P33

in y-axis=Ticket, x-axis=Time spent, legend=Index, but this legend does not give the same colors for all state in a id. Also, tried sorting column  state using Sort by column index which gives an error such as"there can't be more than one value in index for the same state". Would really be helpfull if there's a way to sort state by index and it should have same colors for all ticket id.

Please Note: The legend has to be sorted by index+it should same colors for every state in each id as well well over all other id's.

Thanks for your help in advance

2 REPLIES 2
Bu__
Frequent Visitor

@ValtteriN , if you turn off legend and switch on custom label and put state there, you can observe that color for each state is different because of the sequence/index. Thus i want the sequence+same colors, is this possible in dax to have it sorted and  assign colors same colors to states and put this as a legend?

ValtteriN
Super User
Super User

Hi,

Could you add an image of the issue? Generally speaking the color should be the same between the columns since you can adjust it on series level:

ValtteriN_0-1704779988507.png

 





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

Proud to be a Super User!




Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.