nickawesome07 has asked for the wisdom of the Perl Monks concerning the following question:
Dave thank you for the fast reply, Essentially the list size is 567 lines, the file.csv size is 6436. When the code is run the output is 3.6 million lines. Thanks in advance. The "list" are email addresses, and the file.csv is a list of email addresses. So there can only be 567 matches. Thanks in advance.open(MYINPUTFILE, "<list"); foreach(<MYINPUTFILE>) { my $out = `grep -i "$_" /home/file.csv`; open(OUTPUT, ">>/tmp/file.report"); print OUTPUT "$out\n"; } close(MYINPUTFILE); close(OUTPUT);
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Grep arrays
by davido (Cardinal) on Feb 22, 2013 at 18:51 UTC | |
|
Re: Grep arrays
by CountZero (Bishop) on Feb 22, 2013 at 20:50 UTC | |
|
Re: Grep arrays
by Anonymous Monk on Feb 22, 2013 at 19:58 UTC |