in reply to Converting data from file with multiline records

try this:
# assuming a record starts with a space... my @records = split '\n ',$data; my $header = shift @records; # determine $num_of_records here ... my $re_string = '\s+ (\d+) \s+ '.('(\S+)\s*' x $number_of_records); my $re = qr/$string/x; for (@records) { my @values = /$re/; }
Update: fixed small typo
-- Joost downtime n. The period during which a system is error-free and immune from user input.