I tried to join two csv file based on id with respect to the below
reference.
How to join two CSVs with Apache Nifi
i'm using NiFi-1.3.0
Now i have two csv files.
1.custom.csv
No,Name,ID,Age1,Hik,2201,332,Kio,3300,22

2.gender.csv
ID,Name,Sex2201,Hik,Male3300,Kio,FemaleI try to combine those tables with
"ID" like following endresult.
No,Name,Sex,ID,Age1,Hik,Male,2201,332,Kio,Female,3300,22

I have using following processor structure.
GetFile-SplitText-ExtractText-LookUpRecord-PutFileIn that lookup record i
have configured
RecordReader = "CSVReader"RecordWriter="FreeFormTextRecordSetWriter"
LookUpService="SimpleCSVFileLookUpService"
ResultRecordPath-->/Keykey-->/IDIn that LookUpService i have given path of
the "gender.csv" and setted LookUpKeyColumn and LookUpValueColumn to be
"ID".
In that FreeFormTextRecordSetWriter i have given text
value"${No},${Name},${ID},${Age},${Sex}"
It yields below result only.
No,Name,Sex,ID,Age,1,Hik,Male,2201,33,2,Kio,Female,3300,22,It doesn't have
"sex" column.
I think i could not configured correctly.
i don't know how to use ResultRecordPath & one dynamic attribute(Key)
specification in LookUpRecord?
Can anyone guide me to solve my issue?

Reply via email to