Hi,
I have two files that I wish to compare them. These files have the first and second field in common. I wish to obtain a new file only with the registers of the second file.
I did a program in perl but it is delayed long time, I don`t know why. Is possible to do that with the join command??
Is necesary to order these files before to compare them??
file1.txt
03102088520|047823026|0411171635410411171644580009200093BIANUAL1|P00000614730211110011BIAC7I|BIAC7O|00000D000|0000000000917
012859206|047730485|0411171640360411171645230004700049BIANUAL1|P00000323890211110011BIAC7I|BIAC7O|00000D000|0000000000447
012590129|047724078|0411171658290411171707260008900090BIANUAL1|P00000594900211110011BIAC7I|BIAC7O|00000D000|0000000000857
012405772|047724198|0411171908540411171910160001300016BIANUAL1|P00000105760211110011BIAC7I|BIAC7O|00000D000|0000000000122
....
.
.
file2.txt
03102088520|047823026|0411171555130411171555340000300010MONTDMS1|P000000280002111270110070|0019|00000A000|0000000000021
03102407085|047811617|0411171507320411171507420000100010MONTDMS1|P000000280002111270110070|0032|00000A000|0000000000010
03102845756|047833419|0411171542570411171544170001300016MONTDMS1|P000000448002111270110070|0017|00000A000|0000000000120
03103019838|048940045|0411171500130411171504540004600049MONTDMS1|P000001372002111270110070|0058|00000A000|0000000000441
03103220823|047833215|0411171545100411171549560004700049MONTDMS1|P000001372002111270110070|0017|00000A000|0000000000446
03103234521|047827998|0411171549340411171551420002100023MONTDMS1|P000000644002111270110070|0019|00000A000|0000000000208
Malpa
Thanks for your help.
I have two files that I wish to compare them. These files have the first and second field in common. I wish to obtain a new file only with the registers of the second file.
I did a program in perl but it is delayed long time, I don`t know why. Is possible to do that with the join command??
Is necesary to order these files before to compare them??
file1.txt
03102088520|047823026|0411171635410411171644580009200093BIANUAL1|P00000614730211110011BIAC7I|BIAC7O|00000D000|0000000000917
012859206|047730485|0411171640360411171645230004700049BIANUAL1|P00000323890211110011BIAC7I|BIAC7O|00000D000|0000000000447
012590129|047724078|0411171658290411171707260008900090BIANUAL1|P00000594900211110011BIAC7I|BIAC7O|00000D000|0000000000857
012405772|047724198|0411171908540411171910160001300016BIANUAL1|P00000105760211110011BIAC7I|BIAC7O|00000D000|0000000000122
....
.
.
file2.txt
03102088520|047823026|0411171555130411171555340000300010MONTDMS1|P000000280002111270110070|0019|00000A000|0000000000021
03102407085|047811617|0411171507320411171507420000100010MONTDMS1|P000000280002111270110070|0032|00000A000|0000000000010
03102845756|047833419|0411171542570411171544170001300016MONTDMS1|P000000448002111270110070|0017|00000A000|0000000000120
03103019838|048940045|0411171500130411171504540004600049MONTDMS1|P000001372002111270110070|0058|00000A000|0000000000441
03103220823|047833215|0411171545100411171549560004700049MONTDMS1|P000001372002111270110070|0017|00000A000|0000000000446
03103234521|047827998|0411171549340411171551420002100023MONTDMS1|P000000644002111270110070|0019|00000A000|0000000000208
Malpa
Thanks for your help.