ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Access ExceptionList in Exit Handler

Post new topic  Reply to topic
 Access ExceptionList in Exit Handler « View previous topic :: View next topic » 
Author Message
saurabh867
PostPosted: Sun Jun 27, 2010 8:57 pm    Post subject: Access ExceptionList in Exit Handler Reply with quote

Voyager

Joined: 13 Jun 2010
Posts: 78

Hi,
Is it possible to access the ExceptionList in the handler part of the exit handler.
I have defined an exit handler for a DB operation and want to log the entire exception list inside the handler part but while debugging I could not see the ExceptionList inside the hadler part..
Any idea how to get that?
Back to top
View user's profile Send private message
mgk
PostPosted: Mon Jun 28, 2010 1:08 am    Post subject: Reply with quote

Padawan

Joined: 31 Jul 2003
Posts: 1642

Look up the LOG statement.
_________________
MGK
The postings I make on this site are my own and don't necessarily represent IBM's positions, strategies or opinions.
Back to top
View user's profile Send private message
saurabh867
PostPosted: Mon Jun 28, 2010 7:42 am    Post subject: Reply with quote

Voyager

Joined: 13 Jun 2010
Posts: 78

Actually I want to access the SQLSTATE and Error code etc..., the way we can get in the compute node if we connect the failure terminal of the node throwing exception.
Basically, the way one can debug excpetion list in java after catching.
Is there any work around to replicate the same inside the handler.

Thanks in Advance
Saurabh
Back to top
View user's profile Send private message
smdavies99
PostPosted: Mon Jun 28, 2010 9:11 am    Post subject: Reply with quote

Jedi Council

Joined: 10 Feb 2003
Posts: 6076
Location: Somewhere over the Rainbow this side of Never-never land.

saurabh867 wrote:
.
Basically, the way one can debug excpetion list in java after catching.


IMHO, this is far easier to do in ESQL. I'm sure there will be readers of this forum who would like to know why you want to do this in Java?
Or, are you one of those shops that insist that all error handling is done with Jave & Log4j?
_________________
WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995

Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions.
Back to top
View user's profile Send private message
mqjeff
PostPosted: Mon Jun 28, 2010 10:19 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

smdavies99 wrote:
saurabh867 wrote:
.
Basically, the way one can debug excpetion list in java after catching.


IMHO, this is far easier to do in ESQL. I'm sure there will be readers of this forum who would like to know why you want to do this in Java?
Or, are you one of those shops that insist that all error handling is done with Jave & Log4j?


Urm. I'm reading saurabh867 as saying they WANT to do this in ESQL, as easily as they CAN do it in java, but that it's not that easy.

AFAIK, the DECLARE HANDLER block does not build the ExceptionList tree when it calls the handler. But perhaps MGK will get a little more verbose on this - and take an opportunity to correct me on this subject.
Back to top
View user's profile Send private message
mgk
PostPosted: Mon Jun 28, 2010 11:37 am    Post subject: Reply with quote

Padawan

Joined: 31 Jul 2003
Posts: 1642

Quote:
AFAIK, the DECLARE HANDLER block does not build the ExceptionList tree when it calls the handler. But perhaps MGK will get a little more verbose on this - and take an opportunity to correct me on this subject.


Hi Jeff

As you say, the ExceptionList is not available inside a Handler. However, you can use the SQLCODE, SQLSTATE, SQLNATIVERROR and SQLERRORTEXT to get the these details from the exception inside the handler. These values will be as per their names if the exception is a DB exception, or one of the ones mentioned in the SQLSTATE docs. They can also be user values if it is a user exception.

Kind regards,
_________________
MGK
The postings I make on this site are my own and don't necessarily represent IBM's positions, strategies or opinions.
Back to top
View user's profile Send private message
saurabh867
PostPosted: Mon Jun 28, 2010 9:21 pm    Post subject: Reply with quote

Voyager

Joined: 13 Jun 2010
Posts: 78

Thanks,
I got my answer. SQLCODE,SQLERRORTEXT are sufficient enough to trace back the cause of error.
Actually I was trying to figure out these in the Debug mode but somehow these variables dont appear in the debugger but are accessible for logging.
Thanks for help
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Access ExceptionList in Exit Handler
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.