mbm has asked for the wisdom of the Perl Monks concerning the following question:
I have a csv file like this: "Task1,Task2",ABC,ABC,Mon 05/22/2009,mbm "Task3,Task4",XYZ,XYZ,Mon 05/20/2009,mbm "Task5,Task6",ABC,ABC,Mon 06/25/2009,mbm "Task7,Task8",ABC,ABC,Mon 03/28/2009,mbm I would like to sort this csv file based on the date (ascending) in th +e 4th column above to produce an output as follows: "Task7,Task8",ABC,ABC,Mon 03/28/2009,mbm "Task3,Task4",XYZ,XYZ,Mon 05/20/2009,mbm "Task1,Task2",ABC,ABC,Mon 05/22/2009,mbm "Task5,Task6",ABC,ABC,Mon 06/25/2009,mbm I know there will be some modules to do this. Can you guys help me out + in both approaches (using modules and without using the modules) Thanks for you response in advance! ~Manjunath
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Sort rows in a csv file based on a date column
by linuxer (Curate) on Apr 08, 2009 at 17:27 UTC | |
|
Re: Sort rows in a csv file based on a date column
by apl (Monsignor) on Apr 08, 2009 at 18:05 UTC | |
|
Re: Sort rows in a csv file based on a date column
by bichonfrise74 (Vicar) on Apr 08, 2009 at 21:55 UTC | |
by Anonymous Monk on Apr 17, 2009 at 16:55 UTC | |
by Corion (Patriarch) on Apr 17, 2009 at 17:01 UTC |