This sorts it properly. I'm sure there's a better way to get at that last number, but I'm just stripping out anything that's not a digit.my @sorted=sort{ my $one=substr($a,rindex($a,'|')); my $two=substr($b,rindex($b,'|')); $one =~ s/\D//g; $two =~ s/\D//g; ($one <=> $two) } @database;
In reply to Re: Sorting issues
by the_slycer
in thread Sorting issues
by Stamp_Guy
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |