You should also check the returned status when you parse a line:
my $csv = Text::CSV_XS->new( { binary => 1 } ); my $status = $csv->parse($line); # parse a CSV string into fie +lds
Occasionally, you'll encounter an invalid CSV line and you'll definitely want to handle it. If there are any embedded binary chars, you'll want to set the binary flag when you create the $csv object as I did above.
In reply to Re^2: Getting columns from cvs file in perl
by thezip
in thread Getting columns from csv file in perl
by pnsreee
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |