http://qs321.pair.com?node_id=161867


in reply to Sorting Tab file

You needn't change the split, but you could use a array slice in on the loop (only get the first and fifth column):
my $row = 0; while (<TABFILE>) { chomp; my @fld = split /\t/; my $col = 0; foreach my $token (@fld[0,4]) { $worksheet->write($row, $col, $token); $col++; } $row++; }