system(" cat $file | sort -t\\| +1 -2 > $file.out ") || die "can't sort the file: $!";