in reply to Re^2: Add Data to Hash Reference
in thread Add Data to Hash Reference
How about
my $test = { 'record' => { 'a' => 11, 'b' => 22 } };
Or just:
my $test; $test->{record}->{'a'} = 11; $test->{record}->{'b'} = 22;
If you want to initialize $test->{record} with something (and don't rely on autovivification), initialize it with {}.
|
|---|