Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now
Hello Dear Community,
I have a question.
I have a table like that :
| L1 | L2 | L3 | Result expected |
| True | True | True | 1 |
| True | True | False | 1 |
| True | False | True | 1 |
| True | False | False | 1 |
| False | False | True | 1 |
| False | True | True | 1 |
| False | False | False | 0 |
If he is one true on column then 1
If only false then 0
Can you help me please ?
Thank you.
Solved! Go to Solution.
Hi @Milozebre
Download this sample PBIX file with these examples.
Are they text values or Boolean True/False?
Do you want to do this in Power Query or DAX?
try this in Power Query assuming the column is text
if [L1] = "False" and [L2] = "False" and [L3] = "False" then 0 else 1
In DAX create this calculated column assumgin the column is True/False (Boolean)
Column = IF ([L1] = FALSE() && [L2] = FALSE() && [L3] = FALSE(), 0, 1)
If the columns are text then use this DAX
Column = IF ( CONTAINSSTRING('Table_Text'[L1], "False") && CONTAINSSTRING('Table_Text'[L2], "False") && CONTAINSSTRING('Table_Text'[L3], "False"), 0, 1)
Regards
Phil
Proud to be a Super User!
Hi Milozebre,
This calculated column should work:
Result =
SWITCH (
TRUE (),
'Table'[L1] = TRUE ()
|| 'Table'[L2] = TRUE ()
|| 'Table'[L3] = TRUE (), 1,
0
)
Best regards,
Tim
Proud to be a Super User!
Hi @Milozebre
Download this sample PBIX file with these examples.
Are they text values or Boolean True/False?
Do you want to do this in Power Query or DAX?
try this in Power Query assuming the column is text
if [L1] = "False" and [L2] = "False" and [L3] = "False" then 0 else 1
In DAX create this calculated column assumgin the column is True/False (Boolean)
Column = IF ([L1] = FALSE() && [L2] = FALSE() && [L3] = FALSE(), 0, 1)
If the columns are text then use this DAX
Column = IF ( CONTAINSSTRING('Table_Text'[L1], "False") && CONTAINSSTRING('Table_Text'[L2], "False") && CONTAINSSTRING('Table_Text'[L3], "False"), 0, 1)
Regards
Phil
Proud to be a Super User!
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
Check out the February 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 50 | |
| 47 | |
| 29 | |
| 15 | |
| 14 |
| User | Count |
|---|---|
| 90 | |
| 74 | |
| 40 | |
| 26 | |
| 25 |