in reply to Re: Parsing a csv file from Exchange
in thread Parsing a csv file from Exchange

Very nice, but instead of throwing away the hash each loop, why not store it in an array?
use strict; use Data::Dumper; my @rec; while (<DATA>){ chomp; my %rec; $rec{$1}=$2 while /([^:]*):([^%]*)%{0,1}/xg; push @rec,{%rec}; } print Dumper \@rec; print $rec[0]->{SMTP}, "\n"; print $rec[1]->{SMTP}, "\n";

jeffa

L-LL-L--L-LL-L--L-LL-L--
-R--R-RR-R--R-RR-R--R-RR
B--B--B--B--B--B--B--B--
H---H---H---H---H---H---
(the triplet paradiddle with high-hat)