3 ms·
cat FILE | awk -F(dataseperator) "{print $(number of seperation to print)}" | sort -g | uniq | sort -g
by a904guy 16y ago
cat FILE | awk -F(dataseperator) "{print $(number of seperation to print)}" | sort -g | uniq | sort -g
- deleted 16y ago[deleted]
- uuoc 16y agoAnd you also gain a useless use of cat award: http://partmaps.org/era/unix/award.html http://partmaps.org/era/unix/award.html The above can be written: awk -F(dataseperator) "{print $(number of seperation to print)}" FILE | sort -g | uniq | sort -g
- ralph 16y agoWhat do you and the original poster hope to achieve by ...| sort -g | uniq | sort -g The second sort is doing nothing. And sort can do uniq, saving time and I/O. $ (seq 10; seq 5) | shuf | sort -gu | fmt 1 2 3 4 5 6 7 8 9 10 $