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.
Hello,
I am trying to use the Table.ReplaceValue function and not having much success. I have spent much time looking at and trying various solutions to no avail. Most of the solutions I found were simular to Xiaoxin Sheng's answer in post Solved: Replace value in Power Query based on condition - Microsoft Power BI Community
#"Replaced Value" = Table.ReplaceValue(#"Changed Type",each [Category],each if [PO]=1006 and [Category]="D" then "C" else [Category],Replacer.ReplaceText,{"Category"})
my version is
#"ReplacedValue" = Table.ReplaceValue(#"Renamed Columns", each [EVP], each if [department] = "Unassigned" then "No Department" else [EVP], Replacer.ReplaceText,{"EVP"})
Which of course produces no errors or changes to the EVP column. I am assuming that my version should value in the [department] column and replace the corresponding [EVP] value with "No Department" and if department does not match "Unassigned" then [EVP] would remain as is. Any ideas why this would fail? I am not very clear on what Replacer.ReplaceText is doing so maybe there is a problem there?
I would appreciate your help.
Hi, @bvilten
If your problem is not yet solved, can you provide some sample data for testing? What kind of results do you expect and can you show them with pictures as well?
Best Regards
can you provide some data?
Proud to be a Super User!
User | Count |
---|---|
117 | |
74 | |
62 | |
50 | |
45 |
User | Count |
---|---|
174 | |
125 | |
60 | |
60 | |
57 |