Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredJoin 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.
Hi,
I need to be able to replace all the values in the 'Trade Engagement' column to look like the below when 'EmployeeID' is NOT "1.Subcontractor" or blank.
| EmployeeID | Trade Engagement |
| CARL | Company |
| 1.Subcontractor | 1.Subcontractor |
| ADAM | Company |
| JAMES | Company |
Thanks in advance
Solved! Go to Solution.
hi @dhodgson
not very clear. do you mean something like:
That forumla isn't wokring. All I did was duplicate the EmployeeID column and renamed to 'trade engagement'. I then need to replace all values to 'Company' if they are not 1.subcontractor or a blank field. I tried using the below, however it replaces all text with "Company";
= Table.ReplaceValue(#"Renamed Columns1", each [Trade Engagement], each if [employeeid] <> "1.SUBCONTRACTOR" then "Company" else [Trade Engagement], Replacer.ReplaceText,{"Trade Engagement"})
btw, the first reply is for DAX, it works like:
Apoloigies, was definitley doing this one wrong! This helps. Appreciate it.
hi @dhodgson
try to add a custom column like:
= Table.AddColumn(#"Changed Type", "Custom", each if [EmployeeID] ="1.Subcontractor" or [EmployeeID]=" "
then [EmployeeID]
else "Company")
it worked like:
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 8 | |
| 6 | |
| 3 | |
| 3 | |
| 3 |
| User | Count |
|---|---|
| 11 | |
| 9 | |
| 8 | |
| 7 | |
| 6 |