I have a file which contains already ordered data and I'd like to re-order the file according to the values in one key, without destroying the order of the data in the other keys.
How do I prevent GNU sort from performing row sorting based on the values of keys I have not specified, or how do I specify to GNU sort to ignore a range of keys when sorting?
1 Don't 2 C 1 Sort 2 B 1 Me 2 A
1 Don't 1 Sort 1 Me 2 C 2 B 2 A
sort -k 1,1 <data.txt
Result: unwanted sorting I didn't ask for:
1 Don't 1 Me 1 Sort 2 A 2 B 2 C