I am using UpdateRecord Processor in Nifi where I need to get value from one record path (/amount), add some value to it and put the resulting value to another record path (/result). I could not find any way of doing this. Any help would be great!!
Asked
Active
Viewed 899 times
1
-
what did you mean with : "get value from one record path" ? – maxime G Jan 26 '20 at 19:33
-
I mean using numeric operations on one record path and storing it in another record path – Jan 27 '20 at 04:30
1 Answers
0
Use UpdateRecord
twice.
The first one is
Record Reader CSVReader
Record Writer CSVRecordSetWriter
Replacement Value Strategy Record Path Value
/result /amount
and the second one is
Record Reader CSVReader
Record Writer AvroRecordSetWritter
Replacement Value Strategy Literal Value
/result ${field.value:toNumber():plus(1000)}
where the answer is based on my the other answer, Add two columns together using apache-nifi

Lamanus
- 12,898
- 4
- 21
- 47