in reply to How do I create a sort sub on-the-fly?
The parameters on the sort specify the column, sort direction, and numeric versus ascii sorting.#!/usr/bin/perl use strict; use Data::Table; my $t = Data::Table::fromCSV("data.csv", 0); # No header $t->sort(8,0,0, 0,1,0, 4,0,1, 2,0,1, 1,0,0); print $t->csv;
This produces output that agrees with yours.
It should work perfectly the first time! - toma
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: How do I create a sort sub on-the-fly?
by CharlesClarkson (Curate) on Nov 06, 2001 at 09:46 UTC |