Hi,
I have started looking into the ReplaceTextWithMapping process because I
want to produce a Json file with some look-ups coming for externa files. I
have looked at this:
https://community.hortonworks.com/questions/10005/how-are-mapping-files-formatted-for-the-nifi-repla.html
, but still I am not really comfortable with how the processor works. I am
now familiar with ReplaceText and, as the URL mentioned, the Replacement
Value is defined in an external file. So, say that I have the following
flow:
GetFile -> ReplaceTextWithMapping ->UpdateAttribute -> PutFile
My GetFile would get a Json file that has a simple structure like this:
{"testField" : "fieldValue1"}
And My ReplaceTextWithMapping would have the following values:
Regular Expression = ("[A-Z]")
MappingFile = D:\myFile.dsv
myFile has the following structure:
"Header1" ; "Header2" ; "Header3"
"a" ; "b"; "c"
What am I supposed to include in the MatchingGroup?
In ReplaceText I would do something like this:
Replacement Text = { "myField" : "${attribute1}" } where attribute1 is the
flowfile attribute often created with a prior ExtractText. How do I
reference an external file whose content is the replacement value?
Thank you so much
--
View this message in context:
http://apache-nifi-developer-list.39713.n7.nabble.com/ReplaceTextWithMapping-Usage-tp10190.html
Sent from the Apache NiFi Developer List mailing list archive at Nabble.com.