Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
Hi
I have a table with three true/false columns, let’s call them isTested, isDeployed and isAccepted. From these columns I need to create a bar chart that shows each of these columns in two colors representing the true/false ratio. This proves to be a much more challenging than I expected, and any help would be greatly appreciated!
Thank you
Stefaan
Hi @Stefaan-4365 ,
How about the result after you follow the suggestions mentioned in my original post?Could you please provide more details about it If it doesn't meet your requirement?
Best regards,
Hi @Stefaan-4365 ,
We can try to create a calculated table and a measure to meet your requirement:
calculated table:
Table 2 =
CROSSJOIN (
DATATABLE (
"Category", STRING,
{
{ "isTested" },
{ "isDeployed" },
{ "isAccepted" }
}
),
{ TRUE (), FALSE () }
)
measure:
Rate =
DIVIDE (
SWITCH (
SELECTEDVALUE ( 'Table 2'[Category], BLANK () ),
"isTested", CALCULATE (
COUNTROWS ( 'Table' ),
'Table'[isTested] IN DISTINCT ( 'Table 2'[Value] )
),
"isDeployed", CALCULATE (
COUNTROWS ( 'Table' ),
'Table'[isDeployed] IN DISTINCT ( 'Table 2'[Value] )
),
"isAccepted", CALCULATE (
COUNTROWS ( 'Table' ),
'Table'[isAccepted] IN DISTINCT ( 'Table 2'[Value] )
),
COUNTROWS ( 'Table' )
),
COUNTROWS ( 'Table' ),
0
)
If it doesn't meet your requirement, Could you please show the exact expected result based on the tables that we have shared?
By the way, PBIX file as attached.
Best regards,
@Stefaan-4365 , Create a common dimension with the values true and false. Join them with all three columns. One will active and two will be inactive. Use userelation to make others active
How to use userelation : https://community.powerbi.com/t5/Community-Blog/HR-Analytics-Active-Employee-Hire-and-Termination-tr...
Create a color column like this
Color Date = if(FIRSTNONBLANK(Table[Value],"true") ="true","green","red")
In coditnal fomatting use it after choosing the "Field"
refer
https://docs.microsoft.com/en-us/power-bi/desktop-conditional-table-formatting#color-by-color-values
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
101 | |
69 | |
44 | |
38 | |
30 |
User | Count |
---|---|
157 | |
89 | |
62 | |
46 | |
40 |