Hello,
I need suggestions for my 2 problems in EJB.
1. I am getting an application exception thrown by the entity bean to the client.
The session bean is called by the servlet.
The entity bean is called by the session bean.
I need to catch the sqlexception in my session bean.
2. when i get a exception in my client and do exp.getMessage() , i am getting an entire printstacktrace of that exception.
I like to have the one line exception details instead of printstacktrace.
For example:
if i get a sqlexception from my entity bean,
in the client however i want to the line sqlexception.
thanks in advance for the suggestions.
radhakrishnan.
-
catching sqlexception (1 messages)
- Posted by: Radhakrishnan Nagamuthu
- Posted on: June 25 2002 13:45 EDT
Threaded Messages (1)
- catching sqlexception by sel s on July 08 2002 22:59 EDT
-
catching sqlexception[ Go to top ]
- Posted by: sel s
- Posted on: July 08 2002 22:59 EDT
- in response to Radhakrishnan Nagamuthu
Radha,
Try e.getLocalizedMessage()
you may override this method in order to produce a locale-specific message.
Thanks,
Selva