Thanks for your prompt response.

As you are aware, getErrorCode() method of
SQLException returns the vendor specific SQL error
code, but there is no getErrorMessage() method.  Since
this is the case, how can I get the actual error
message if I implement according to your suggestion?

Please do you have any example in which this is
implemented?  Alternatively, do you know of any site
that has an example.

Thank you.

Ola





--- Robert Taylor <[EMAIL PROTECTED]> wrote: > One
strategy is to wrap the SQLException thrown by
> mySQL
> in a meaningful ApplicationException which can be
> caught in your action class
> or declarative exception handling mechanism and
> "interpretted"
> into the appropriate client error message which can
> be placed
> in the appropriate scope (request or session) which
> can in turn
> be rendered in the .jsp page.
> 
> robert
> 
> > -----Original Message-----
> > From: Research labs
> [mailto:[EMAIL PROTECTED]
> > Sent: Saturday, July 17, 2004 8:27 AM
> > To: Struts Users Mailing List
> > Subject: outputting mysql (or any other database)
> error in jsp
> > 
> > 
> > Can anyone please tell me the best way to get a
> > database error into my java code so that I can
> output
> > the database error in a JSP etc.
> > 
> > My key problem is how to pass the database error
> to my
> > Java code.  
> > 
> > Thank you.
> > 
> > Ola.
> > 
> > 
> >     
> >     
> >             
> >
>
___________________________________________________________ALL-NEW
> Yahoo! Messenger - sooooo many all-new ways to
> express 
> > yourself http://uk.messenger.yahoo.com
> > 
> >
>
---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> > For additional commands, e-mail:
> [EMAIL PROTECTED]
> > 
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> For additional commands, e-mail:
> [EMAIL PROTECTED]
> 
>  


        
        
                
___________________________________________________________ALL-NEW Yahoo! Messenger - 
sooooo many all-new ways to express yourself http://uk.messenger.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to