in reply to How to sort a AoH reference

I think your question are answered... replace, or initialize scalar variable with an array, to change to array context... (all sort function samples use array context)

use Data::Dumper; $Data::Dumper::Indent=0; my @x = sort qw( 1 2 3 4 5 ); my $x = sort qw( 1 2 3 4 5 ); my $y = []; @$y = sort qw( 1 2 3 4 5 ); print Dumper(\@x, $x, $y ); __END__ $VAR1 = [ '1', '2', '3', '4', '5' ]; $VAR2 = undef; $VAR3 = [ '1', '2', '3', '4', '5' ];
But my question... Why don't use mysql todo it as I fetchall_arrayref it from MySQL ?!

In my concepts... use perl always... when Perl Power is needs!

--
Marco Antonio
Rio-PM