General :: Replace Data - Transaction IDs And Corresponding Value
Dec 22, 2010I have two files one of which having some Transaction IDS and corresponding value whose sample content as follows:
Code:
SDP-DM-100689014,8.0
SDP-DM-100689202,30.0
And in second file complete details of all Transaction IDs and sample content as follows and delimeter used is comma(,):
Code:
SDP-DM-100689014,2010-12-21 19:24:29 GMT+05:30,CRBT,18,UK,Default,B_11170244,9058629605,405818120653083,,Pre-Paid,Comviva,default_provider,009114500001366,,0.0,code0,0,,Caller Tune,,UK#11561723,,1292939663242,VAS0003ALL,52211,,,UK,,0.0,Grace,
SDP-DM-100689202,2010-12-21 19:24:34 GMT+05:30,Subscription,4,BJ,,B_12326406,9122828964,405876120814560,,Pre-Paid,,default_provider,4945,,40.0,,0,,,,BJ#12106840,,-2206657c%3A12d08f49330%3A4812,VAS0003ALL,,OBD,RECURRING,BJ,,,,
And I want is if column number 1 of first file which is transaction ID matches with column number 1 of second file which is transaction ID than 18th column of second file is replaced with data provided on first file with the respective transaction ID. Example of output as follows:
Code:
SDP-DM-100689014,2010-12-21 19:24:29 GMT+05:30,CRBT,18,UK,Default,B_11170244,9058629605,405818120653083,,Pre-Paid,Comviva,default_provider,009114500001366,,0.0,code0,8.0,,Caller Tune,,UK#11561723,,1292939663242,VAS0003ALL,52211,,,UK,,0.0,Grace,
SDP-DM-100689202,2010-12-21 19:24:34 GMT+05:30,Subscription,4,BJ,,B_12326406,9122828964,405876120814560,,Pre-Paid,,default_provider,4945,,40.0,,30.0,,,,BJ#12106840,,-2206657c%3A12d08f49330%3A4812,VAS0003ALL,,OBD,RECURRING,BJ,,,,