There are a few ways, but here's one:
@$data = sort { $a->{order} <=> $b->{order} } @$data;
--
print "Just Another Perl Adept\n";
In reply to Re: sorting a list of hashes on an element/attribute of the hash
by vrk
in thread sorting a list of hashes on an element/attribute of the hash
by perlnovice1
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |