I have a loop, each iteration through the loop the hash %tmpEntry gets a
new set of values.
And each iteration through the loop I place this hash into another hash,
like so:
[snip]
print "Added entry.\n";
$oncall{$tmpEntry{'StartDate'}} = \%tmpEntry;
[snip]
tmpEntry is defined outside the loop, because I need to handle the last
case outside of the loop.
This doesn't work, all the entries end up being the same, because of the
reference to the memory location.
I need something similar ...I thought about taking each value of tmpEntry
and setting each variable like so:
$oncall{$tmpEntry{'StartDate'}}->{x} = $tmpEntry{x};
$oncall{$tmpEntry{'StartDate'}}->{y} = $tmpEntry{y};
but that seem inelegant at best.
Thoughts ?
-----------------------------------------
Craig Moynes
[EMAIL PROTECTED]
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]