in reply to Sorting an array of hashes

Would be nice if you showed us the code you've tried so we can explain where your misunderstandings are.

But this will do what you want.

@job_data = sort { $a->{runs} cmp $b->{runs} } @job_data;
--
<http://www.dave.org.uk>

"The first rule of Perl club is you do not talk about Perl club."
-- Chip Salzenberg

Replies are listed 'Best First'.
Re^2: Sorting an array of hashes
by Scarborough (Hermit) on Jul 28, 2004 at 08:58 UTC
    Good piont but if you saw the complicated way I went about it you would understand my embrassment.
    I guess K.I.S.S should be kept well and truely in my field of vision.