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!The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!
Why do these give an error:
= Table.AddColumn(#"Changed Type, "COMPARE", each if[TEXT]<>[TEXT.1] then Text.Length([TEXT]) &" vs. "& Text.Length([TEXT.1]) else "=")
= Table.AddColumn(#"Changed Type, "COMPARE", each if[TEXT]<>[TEXT.1] then Text.Combine({Text.Length([TEXT]), Text.Length([TEXT.1])}, " vs. ") else "=")
= Table.AddColumn(#"Changed Type, "COMPARE", each if[TEXT]=[TEXT.1] then "=" else Text.Length([TEXT]) &" vs. "& Text.Length([TEXT.1]))
= Table.AddColumn(#"Changed Type, "COMPARE", each if[TEXT]=[TEXT.1] then "=" else Text.Combine({Text.Length([TEXT]), Text.Length([TEXT.1])}, " vs. "))
Alternatives? (I want to be able to "see" the diff between 2 text columns.)
Solved! Go to Solution.
it would have been easier to help you if you had written the error it gives you for each of the expressions.
For example, for the former, the problem could be that Power Query cannot concatenate numbers and text.
For this you should convert the numeir to text. Thus, for example:
= Table.AddColumn(#"Changed Type, "COMPARE", each if[TEXT]<>[TEXT.1] then Text.From(Text.Length([TEXT])) &" vs. "& Text.From(Text.Length([TEXT.1])) else "=")
...
it would have been easier to help you if you had written the error it gives you for each of the expressions.
For example, for the former, the problem could be that Power Query cannot concatenate numbers and text.
For this you should convert the numeir to text. Thus, for example:
= Table.AddColumn(#"Changed Type, "COMPARE", each if[TEXT]<>[TEXT.1] then Text.From(Text.Length([TEXT])) &" vs. "& Text.From(Text.Length([TEXT.1])) else "=")
...
You're right (of course)!! (Still learning)
Expression.Error: We cannot apply operator & to types Number and Text.
The Power BI Data Visualization World Championships is back! It's time to submit your entry.
Check out the January 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 18 | |
| 13 | |
| 9 | |
| 8 | |
| 8 |