Perl - Compare two files and copy intire line to final.log
- by user2977141
I need perl script to compare line from file1 with file2 and copy to final file, something like this:
File1.txt:
ASPO01
ASPO02
ASPO03
File2.txt:
ASPO01 2013-11-10 19hrs
ASPO10 2013-11-09 24hrs
ASPO02 2013-11-08 10hrs
ASPO16 2013-11-05 9hrs
ASPO17 2013-11-06 6hrs
ASPO03 2013-11-07 15hrs
ASPO18 2013-11-02 25hrs
...
Search into File2 and copy to final file called final.log, like this:
final.txt:
ASPO01 2013-11-10 19hrs
ASPO02 2013-11-08 10hrs
ASPO03 2013-11-07 15hrs
Thanks for all good friends can help me!!!