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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
Wasabiii
Frequent Visitor

Stacked Bar chart with true/false for multiple fields managing a lot of rows

Hello everyone ! 

 

I know that there is several subjects about stacked bar with true/false, but every solution i saw used the unpivot column.

I have a table with +-10 columns true/false. From these columns I need to create a bar chart that shows each of these columns in two colors representing the true/false ratio.

I can't unpivot because i manage >300 000 rows soo it can't be convertible in columns.

 

I don't know if its possible ^^' Below some links that finaly didn't match with my idea : 

https://community.fabric.microsoft.com/t5/Desktop/Create-table-containing-count-of-True-false-of-mul...

https://community.fabric.microsoft.com/t5/Desktop/True-False-Column/m-p/591435

https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Count-True-False-values-in-multiple-...

https://community.fabric.microsoft.com/t5/Desktop/Bar-chart-with-true-false-ratio/td-p/1061981

https://communities.gainsight.com/customer-success-cs-15/chart-showing-yes-no-or-true-false-count-fo...

 

2 REPLIES 2
lbendlin
Super User
Super User

I can't unpivot because i manage >300 000 rows soo it can't be convertible in columns.

That's not what unpivoting is about, quite the opposite.

 

Please provide sample data that covers your issue or question completely, in a usable format (not as a screenshot).

Do not include sensitive information or anything not related to the issue or question.

If you are unsure how to upload data please refer to https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-...

Please show the expected outcome based on the sample data you provided.

Want faster answers? https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447...

Hello Ibendlin,

Here is a sample data : 

CODEisStrongisUselessisSameToAnotherreasonDeletion
2090010Useless
21800010Useless
25563010Useless
36194010Useless
43116010Useless
69529000Not Strong
73564000Not Strong
82177110Useless
84812110Useless
84813100None
84814101Same to another
84815100None
84816100None
84817110Useless
84818110Useless
84819110Useless
84820110Useless
84821110Useless
84822100None
84823100None
84824100None
84825100None
84814101Same to another

 

In Power query i want to have this result at the end : 

CATTrueFalse
isStrong167
isUseless1211
isSameToAnother221

 

So i tried to do a group on the table by using the reason deletion : 

Table.Group(#"Changed column type 2", {"reasonDeletion"}, {{"True", each List.Sum(List.Combine({[#"isUseless"], [#"isStrong"], [#"isSameToAnother"]}))}})
 
And im blocked here because my group by function doesn't work (obviously), but in DAX i can create a column and just write this after creating a new table with a column "Type" with two rows (True and False) :
col_isUseless = COUNTX(FILTER(ALL('Table'),'Table'[isUseless] = NewTableDAX[Type]), 'Table'[isUseless]) / COUNTROWS('Table')
So i can have this in DAX Wasabiii_0-1703672590564.png

 

And i can do the stakedbar chart with true false correctly :

Wasabiii_1-1703672771218.png

 

But my problem is that i use DAX and i want to have a table already correct in my dataflow soo it's why i ask for a solution in power query (and i think i'm in the good way but im blocked with that group by).

 

I hope that the details provided will help to better understand my problem.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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