Jeffro Tull has asked for the wisdom of the Perl Monks concerning the following question:
open (regfile, ">>$datadir/projects\.dat") || "Cannot open File1."; my @regfile = <regfile>; close (regfile); open (NEWFILE,">>$datadir/subscribe\.dat") || "Cannot open File2."; foreach $i (@regfile) { ($b, $b, $b, $b, $base_email, $b, $b, $b) = split (/\|/, $i); If ($base_email\|$name\|$date\|$format ne ANY LINE IN NEWFILE) { print NEWFILE "$base_email\|$name\|$date\|$format\n"; } } close (NEWFILE);
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: How to delete lines with similar data
by mirod (Canon) on Feb 05, 2002 at 11:15 UTC | |
|
Re: How to delete lines with similar data
by gmax (Abbot) on Feb 05, 2002 at 11:06 UTC | |
|
Re: How to delete lines with similar data
by gellyfish (Monsignor) on Feb 05, 2002 at 10:53 UTC | |
|
Re: How to delete lines with similar data
by jmcnamara (Monsignor) on Feb 05, 2002 at 11:53 UTC | |
by Jeffro Tull (Novice) on Feb 05, 2002 at 14:21 UTC | |
|
Re: How to delete lines with similar data
by metadoktor (Hermit) on Feb 05, 2002 at 10:14 UTC |