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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
Lorenski
Frequent Visitor

100% stacked bar/column chart - sort by percentage

I know this has been posted several times, and I've tried numerous Google searches.  But am still failing to get the result I desire.

 

Like many others, I need a 100% stacked bar/column chart to be sorted by the good percentage.  I have a bunch of work centers (machines) that are being monitored.  On one graph, I have the count of good vs scrap parts.  Then on another graph, I have the percentage of good vs scrap.  I want to sort by work center/machine with the highest percentage of good parts.  So far, I've been unable to accomplish this.

 

Here's my current percentage chart:

Lorenski_0-1656610634980.png

 

 

 Here is the current count chart (This is what I want the percentage chart to look like! Highest percentage of good/green at the left):

Lorenski_1-1656610087457.png

And here is my data table this is coming from (I added the % column myself, when I was reading other threads/videos & trying to make this sort correctly):

Lorenski_0-1656610732094.png

 

 

Thank you in advance for any help!

1 ACCEPTED SOLUTION
otravers
Community Champion
Community Champion

Can you try creating a DAX measure for "good %" and put it in the stacked column chart to use it as your sorting measure?

------------------------------------------------
1. How to get your question answered quickly - good questions get good answers!
2. Learning how to fish > being spoon-fed without active thinking.
3. Please accept as a solution posts that resolve your questions.
------------------------------------------------
BI Blog: Datamarts | RLS/OLS | Dev Tools | Languages | Aggregations | XMLA/APIs | Field Parameters | Custom Visuals

View solution in original post

2 REPLIES 2
Lorenski
Frequent Visitor

@otravers 

 

Thank you!  I had a feeling it would be something simple by the time I got to posting here 😄

 

So, to recap for other readers: in my original post, I was trying to use a calculated column and not a DAX measure.  After @otravers reply, I had to brush up on calculated column vs measure.  Once I came up with the right measure, then put that into the Tooltips, then sorted by in the upper right of the chart, I got what I needed:

 

Lorenski_0-1656617850410.png

Lorenski_1-1656617985906.png

 

otravers
Community Champion
Community Champion

Can you try creating a DAX measure for "good %" and put it in the stacked column chart to use it as your sorting measure?

------------------------------------------------
1. How to get your question answered quickly - good questions get good answers!
2. Learning how to fish > being spoon-fed without active thinking.
3. Please accept as a solution posts that resolve your questions.
------------------------------------------------
BI Blog: Datamarts | RLS/OLS | Dev Tools | Languages | Aggregations | XMLA/APIs | Field Parameters | Custom Visuals

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

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