http://qs1969.pair.com?node_id=87229


in reply to Extracting array of hashes from data

This line seems to be your problem:

$alldata{$key} = push [ %temphash ];

you probably really meant to push %temphash on to the array ref in $alldata{$key}. In that case you can reference that array with @{ $alldata{$key} }. Then you can just push a reference to %temphash on top of it:

push @{ $alldata{$key} }, \%temphash;

(the array will be automatically created as needed)

Of course see perldsc and perlref if you haven't already.

update: Typo fixed. Thanks srawls.