in reply to [SOLVED] generate array of hashes

You are doing something that we cannot see, the following works just fine:

use strict; use warnings; my %hoh ; my ($dn,$mail) = qw( dn mail ); my @members = qw(foo bar baz); my @email_addrs = qw( foo@here bar@there ); my $rec = { DN => $dn, MAIL => $mail, MEMBERS => [ @members ], PROXYADDRS => [ @email_addrs ], }; $hoh{$dn} = $rec; use Data::Dumper; print Dumper \%hoh;

While it is great to isolate your problem, be sure and post a complete example. It helps with the rubber ducking process. :)

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)

Replies are listed 'Best First'.
Re^2: generate array of hashes
by stevieb (Canon) on Dec 10, 2015 at 22:03 UTC
    For completeness... GrandFather pointed this out to me not too long ago (I'm pretty sure of that... If I'm mistaken, I apologize). Rubber duck debugging. We all do it :)