Hi! Today I've ran into a problem of the sort ignoring the --key parameter. It sorts data according to the alphanumeric order of the full string instead. Twiddling here and there (coreutils version, LC_ALL, positions, etc) did not work. Any ideas?
harvest$ zcat data.log.gz | pcregrep '[TR]data' | head -10 | sort --key=17,30 0_01_18_139_840 vtt1_100 vtt2_9#8 Tdata (0,8132) 0_01_19_377_086 vtt1_100 vtt2_9#8 Tdata (0,8132) 0_01_19_771_887 vtt1_100 vtt1_6#2 Tdata (0,7832) 0_01_19_794_385 vtt1_100 vtt1_2#3 Tdata (0,7832) 0_01_20_456_841 vtt1_100 vtt1_23#4 Tdata (0,8132) 0_01_21_444_514 vtt1_100 vtt2_6#7 Tdata (0,8132) 0_01_21_444_752 vtt1_100 vtt1_26#5 Tdata (0,7832) 0_01_22_944_496 vtt1_100 vtt2_8#9 Tdata (0,7835) 0_01_23_498_353 vtt1_100 vtt2_26#10 Tdata (0,7835) 0_01_23_612_298 vtt1_100 vtt1_4#6 Tdata (0,7832) harvest$ sort --version sort (GNU coreutils) 8.5 Copyright (C) 2010 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>. This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Written by Mike Haertel and Paul Eggert. harvest$ env TERM=xterm-color SHELL=/bin/bash SSH_TTY=/dev/pts/32 LC_ALL=C PATH=/home/victor/bin:/usr/local/bin:/usr/bin:/bin:/usr/games LANG=en_US.UTF-8 PS1=\W\$ SHLVL=1 _=/home/victor/bin/env harvest$ -- V
