Hi All,
Seeking for your assistance regarding on how to bash file 1 and file 2 then add the field if the bash is true.
Ex.
nik1.csv - input file 1
1,0054,0001,4,5,6,7,May 1,USA
11,0053,0002,14,15,16,17,May 2,PHL
40,0052,0003,43,44,45,46,May 5,GER
nik2.csv - input file 2
20,21,22,23,24,0054,0001,May 5
30,31,32,33,34,0053,0002,May 7
Input File 2 Expected Output:
20,21,22,23,24,0054,0001,May 5,USA
- Added the 8th Field(USA) because the the 6th and 7th field of input file 2 is equal to 2nd and 3rd field of input file 1.
30,31,32,33,34,0053,0002,May 7, PHL
- Added the 8th Field(PHL) because the the 6th and 7th field of input file 2 is equal to 2nd and 3rd field of input file 1.
If the 6th and 7th field of input file 2 is equal to 2nd and 3rd field of input file 1, i'm going to add the 8th field of input file 1 into input file 2.
I don't know how to code it. T_T
Please advise,
Thanks,
-nik
---------- Post updated at 11:52 AM ---------- Previous update was at 11:03 AM ----------
Seeking on assistance pls..
Thanks,
-nik