in reply to Re^2: How to use perl to parsing a XML file to csv file which have the same sequence in xml file?
in thread How to use perl to parsing a XML file to csv file which have the same sequence in xml file?
It worked on my machine, but Text::CSV's behaviour can be a little variable - it has two underlying implementations: one in pure Perl, and a faster one in C. Which one you get is the luck of the draw. In this case, $row is a blessed arrayref; Text::CSV expects an arrayref; it looks like one of the implementations rejects the arrayref if it's blessed but the other does not.
$csv->print(\*STDOUT, [@$row]); # unblessed shallow clone of $row
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: How to use perl to parsing a XML file to csv file which have the same sequence in xml file?
by Anonymous Monk on Dec 31, 2012 at 03:48 UTC |