tag 35636 notabug thanks On 5/8/19 3:35 AM, Michele Liberi wrote: > I verified the following bug is there in: > > - sort (GNU coreutils) 8.21 > - sort (GNU coreutils) 8.22 > - sort (GNU coreutils) 8.23 > > *Input file:* > # cat sort.in > 1|a|x > 2|b|x > 3|aa|x > 4|bb|x > 5|c|x > > > *shell command and output:* > # sort -t'|' -k2 3|aa|x > 1|a|x > 4|bb|x > 2|b|x > 5|c|x Let's use --debug to see what sort really did: $ sort --debug -t'|' -k2 > *I expected that key "a" to come before key "aa" and key "b" to come before > key "bb".* Your expectations are at odds with your incomplete command line. sort is behaving as required; therefore, I'm closing this as not a bug. But feel free to reply if you have further questions. -- Eric Blake, Principal Software Engineer Red Hat, Inc. +1-919-301-3226 Virtualization: qemu.org | libvirt.org