in reply to Re: how to substitute next line with nothing
in thread how to substitute next line with nothing

I think the question was not how to extract the fields, but how to exclude duplicate records.

I think in this case it's easiest to just use a hash to record the names, for example:

my %seen=(); ... while(<INPUT_FILE>) { my @fields=split /=/; $fields[1]=/^(\d+)/; my $id=$1; $fields[2]=/^(\w*)/; my $name=$1; $seen{$name}=[$id,$fields[5]]; }
If a name occurs several times, the last occurence is recorded and the other ones discarded.

-- 
Ronald Fischer <ynnor@mm.st>