Re: Tie::Handle::CSV



On Wednesday 27 June 2007 17:54, Tom Phoenix wrote:

My best guess is that somewhere near end of file, Tie::Handle::CSV is
using Carp to report an error, but it's not doing a very good job of
telling you what the error actually is. See whether adding this to
your program gives you the full stack backtrace:

BEGIN { $Carp::Verbose = 1 }

When you find the problem, I'm sure that the module's author would
appreciate a patch that improves the error handling. Good luck with
it!


Thanks Tom.

I added the line immediately after the #!/usr/bin/perl line and ran the
script. It didn't give any output, but when I redirected the output to VIM it
reported the error line as

^Z at ../bin/walon line 25

It looks like Tie::Handle::CSV just dies when there are no records left.

I've looked at the perldoc for the module and I can't see any reference to why
it should do this, or how to stop it.

--
Gary Stainburn

This email does not contain private or confidential material as it
may be snooped on by interested government parties for unknown
and undisclosed purposes - Regulation of Investigatory Powers Act, 2000
.



Relevant Pages