sort command SUMMARY

From: John Elser <jElser_at_ck8.uscourts.gov>
Date: Tue Sep 23 2003 - 09:47:22 EDT
Thanks to everyone that replied.  John Leadeham sent me the simplest solution.
Which was:
sort -k10.7n,10.10n -k10.1,10.2n -k10.4,10.5n filename

My problem was that I'm using an old sort command which for some reason
doesn't work when using the -k option.  Even though it is stated in the man
pages.

Thanks again



Original posting:
I'm having trouble getting a text file to sort properly.  I have a text file
with a date (ie. 02/14/2002) in the 10th field.  I want to sort the file from
earliest to latest but I'm having a problem getting the correct sort command
that will first sort it by year and then by month, day.

Sorry for such an elementary question.  I've checked out the man pages, but
nothing seems to work.
_______________________________________________
sunmanagers mailing list
sunmanagers@sunmanagers.org
http://www.sunmanagers.org/mailman/listinfo/sunmanagers
Received on Tue Sep 23 09:47:19 2003

This archive was generated by hypermail 2.1.8 : Thu Mar 03 2016 - 06:43:20 EST