Beefy Boxes and Bandwidth Generously Provided by pair Networks Bob
Syntactic Confectionery Delight
 
PerlMonks  

Re^3: Carp not working after change to objects

by snoopy (Chaplain)
on May 17, 2008 at 02:12 UTC ( #687059=note: print w/ replies, xml ) Need Help??


in reply to Re^2: Carp not working after change to objects
in thread Carp not working after change to objects

Sorry this didn't help.

Btw, I'm not able exactly replicate your error with my Sqlite driver. My prepare statement on an unknown table returns undef, not a valid statement handle.

my $sth = $dbh1->prepare("insert into guff values (1,2,3)") or croak "prepare error" # dies here for me

If you're not raising errors, be aware that prepare may return undef.

Also consider localisd error handling. You still has the option of dieing or continuing:

my $dbh = DBI->connect(... ,{RaiseError => 1}); do { local $SIG{__ERROR__} = \&my_handler; # database code }


Comment on Re^3: Carp not working after change to objects
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (12)
As of 2013-05-23 10:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best material for plates (tableware) is:









    Results (478 votes), past polls