combine derived column expression

arkiboys 9,706 Reputation points
2023-08-04T13:52:16.64+00:00

in dataflow I am using a derivedColumn_1 with the following expression:

replace(Column_1, '},"additionalDetails"', '}],"additionalDetails"')

in derivedColumn_2 with the following expression:

replace(Column_1, '},"company"', '}],"company"')

question,

is it possible to put both of the above into one derived column expression?

thanks

Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
{count} votes

Answer accepted by question author
  1. QuantumCache 20,676 Reputation points Moderator
    2023-08-04T19:49:25.28+00:00

    Hello @arkiboys

    Does your source data looks like the below one ? and you want to update the incoming data by using one expression?

    User's image

    Did you try to use the replace function in the same expression twice?

    Something like:

    replace(replace(Column_1, '},"additionalDetails"', '}],"additionalDetails"'), '},"company"', '}],"company"')
    
    1 person found this answer helpful.

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.