|
|
| The stupid question is the question not asked | |
| PerlMonks |
Re: merging content based on common columns of 2 files using grepby citromatik (Curate) |
| on May 06, 2009 at 11:49 UTC ( #762235=note: print w/ replies, xml ) | Need Help?? |
|
First of all, you should use strict; and use warnings; if you want to learn Perl the easy way There are some errors in your code, some of them:
Here is a working version of your program:
You should also consider using hashes to solve your problem Another alternative, if the script is only going to join both files and output the result (and you are in a Unix/Linux system, as it seems to be the case) is to use bash's join tool:
citromatik
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||||