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
Greetings,
I'm working on a conditional output, that will swich output table (if it's empty) to the predefined one. The code goes as:
#"Filtered Rows4" = Table.SelectRows(#"Added Custom3", each ([Custom] = "Object missing")),
Test = Table.IsEmpty(#"Filtered Rows4"), // returns TRUE, as logical value type I guess
TestOKTable = Table.FromRecords({[Message = "OK"]}),
Output = (if Test = "TRUE" then TestOKTable else #"Filtered Rows4") //no matther what, always returns #"Filtered Rows4" with 0 rows
in
Output
I'm looking for a hint what am I doing wrong, tried the Output = (if Test = TRUE then TestOKTable else #"Filtered Rows4") but returns error, seems I'm not able to properly refer to the TRUE result.
EDIT: the solution was simple, to refer properly to logical value is was required to write the code as:
Output = (if Test = true then TestOKTable else #"Filtered Rows4") // lower case need to be used without quotation
Case resolved....
Would appreciate any feedback.
Solved! Go to Solution.
You can simply this with just:
if Test then TestOKTable else #"Filtered Rows4"
You can simply this with just:
if Test then TestOKTable else #"Filtered Rows4"
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 |
|---|---|
| 16 | |
| 12 | |
| 9 | |
| 7 | |
| 6 |