I've found a couple of examples of moving an array into a hash, but not of moving a hash into an array.
I thought this would work: @sorted = sort { $myhash{$b} <=> $myhash{a} } keys %myhash ; while ( <@sorted> ) { printf ( "first field = %s second field = %s\n", $sorted{1}, $sorted{2} ) ; } I am trying to sort the hash values (by value, not key) and move the sorted results into an array, so that I can add additional fields later. I get an "Use of uninitialized value at ./newlogscan.pl line 46." error. Line 46 is the @sorted = line. Any ideas? Craig Hammer Internal Infrastructure Team Lead Parago, Inc. 972-538-3936 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]