Re: DBI in a web context
- From: dispo41@xxxxxxxxxxx (Chris)
- Date: Thu, 16 Nov 2006 22:53:27 +1100
Read up on how to connect in the first place - you can pass
a switch that tells it to return errors to you, instead of killing
your whole script.
Look here:-
http://search.cpan.org/~pythian/DBD-Oracle-1.19/Oracle.pm#plsql_errstr
and search for "RaiseError"
"Robert Hicks" <sigzero@xxxxxxxxx> wrote in message
news:20061110204022.18141.qmail@xxxxxxxxxxxxxxxxxxxxxxx
I have a couple forms for an in-house application. The user fills out the
fields and then submits which update a back end Oracle database.
I have looked for examples but can't really find anything.
How is it best to catch errors when doing DBI stuff in web applications?
Wrap the insert "code" in an eval statement? Croak or die statements? I am
thinking eval because I can set autocommit to "off" and then do rollbacks
if $@ has an error.
Suggestions and comments welcome?
Robert
.
- References:
- DBI in a web context
- From: Robert Hicks
- DBI in a web context
- Prev by Date: Re: Creating XML from an Oracle DB
- Next by Date: How should I connect via DBD::Oracle to efficiently obtain 2000+ simultaneous connections?
- Previous by thread: Re: DBI in a web context
- Next by thread: Possible Problem with bind_param
- Index(es):
Relevant Pages
|