in reply to Recursive hash assignment
I've managed to write a solution to this problem that works, of sorts, but its *very* slow, especially with large tables (25,000 rows+).
My code's below - any suggestions on how to improve the speed of this would be very much appreciated.
my @tmpHash; my $lastKey = $keys[$#keys]; %{$tmpHash[$#keys]{$tblData{$lastKey}}} = %tblData; if ($#keys >= 1) { for (my $n = $#keys - 1; $n >= 0; $n--) { %{$tmpHash[$n]{$tblData{$keys[$n]}}} = %{$tmpHash[$n+1 +]}; } } %tableData = (%tableData, %{$tmpHash[0]});
--Foxcub
|
|---|