#!perl -w use strict; use Text::CSV_XS; use IO::File; my $csv = Text::CSV_XS->new( {binary=>1} ); my $fh = IO::File->new('tmp.csv'); while (my $cols = $csv->getline($fh)) { last unless @$cols; printf "%s\n", join ':',@$cols; }