Forum Discussion

GermanAndres's avatar
GermanAndres
Frequent Visitor
3 years ago
Solved

How to replace only existing values in join? Is there a better way?

So here's the problem, I have two datasets, one has a lot of data, but with some outdated fields and the other has some specific columns with updated data. The nomber of columns is rather arbitrary, ...
  • v-yanjiang-msft's avatar
    3 years ago

    Hi GermanAndres ,

    According to your description, here's my solution. Add a step in advanced editor of the Outdated table:

    #"Replace Value" = Table.ReplaceValue(#"Changed Type",each [L1], each try Table.SelectRows(#"Table",(x)=>x[Date]=[Date])[L1]{0} otherwise [L1], Replacer.ReplaceValue,{"L1"})

    #"Table" in the formula is the table with new data. Get the correct result:

    I attach my sample below for your reference.

     

    Best regards,

    Community Support Team_yanjiang

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.