in reply to Cannot work on second file after reading first file.
The immediate problem is the undef $/; in open_po. Replace it with local ($/);
A couple notes on my process for debugging this:
First, I used Data::Dumper to dump the result of call $csv->getline_all to see the entire parse being returned. This verified the only thing being returned was the header row.
Then I commented out the call to open_po and saw that the file was not being parsed correctly. This meant the problem was some state being globally modifed in open_po.
Study of that sub lead to the problem
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Cannot work on second file after reading first file.
by 1straw (Novice) on Feb 28, 2014 at 19:06 UTC |
In Section
Seekers of Perl Wisdom