1 very stupid question
sort -t ':' +0 -1 -n +1 -2 +2 -3 -o list list
will the Field 1 that is 2008-07-17| be sorted in numerical order?
I always thought the parameter -n is only meant for fields mentioned preceding it.that is +0 -1 ?
000|2008-07-17|556543|RTJ|35-RTGJ|EYT
465|2008-11-10|567789|GHJ|45-DGHH|ETU
533|2008-09-06|567789|GHJ|45-DGHH|ETU
Then
sort -t ':' +0 -1 +1 -2 -n +2 -3 -o list list would mean the same thing.I also gotta learn that the field 000 is Field 0.
Is it the same case with awk '|' print $1 on the line 000|2008-07-17|556543|RTJ|35-RTGJ|EYT .Will it print 2008-07-17?
Thanks a lot,