Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re: Parsing output from the CSV file

by manorhce (Beadle)
on Feb 07, 2013 at 19:51 UTC ( #1017719=note: print w/ replies, xml ) Need Help??


in reply to Parsing output from the CSV file

Use like the below it will parse the data and will create fields according

$csv = Text::CSV::Simple->new({ sep_char => q{,}, binary => 1 }); $csv->field_map( qw( field1 field2 field3 field4 ) ); my @objectlist = $csv->read_file($file_name); foreach my $data (@objectlit) { print $data->{field1}."field2",$data->{field2} }


Comment on Re: Parsing output from the CSV file
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1017719]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (4)
As of 2014-10-25 09:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    For retirement, I am banking on:










    Results (142 votes), past polls