|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
DECLARE HANDLER for PARSE |
« View previous topic :: View next topic » |
Author |
Message
|
fabyos |
Posted: Mon Jun 22, 2009 2:23 pm Post subject: DECLARE HANDLER for PARSE |
|
|
Apprentice
Joined: 15 May 2009 Posts: 37
|
Hi,
I read some topics here related to DECLARE HANDLER and none of them appear to be solved when the topis is PARSE.
I'm stuck with this, and I know that the DECLARE HANDLER is correct because it catches USER EXCEPTION... currently I've this code:
Code: |
BEGIN
DECLARE CONTINUE HANDLER FOR SQLSTATE LIKE '%'
BEGIN
-- do something
END;
-- THROW USER EXCEPTION VALUES('handle this!');
CREATE LASTCHILD OF OutputLocalEnvironment.Variables DOMAIN('MRM') PARSE(
InputRoot.BLOB
OPTIONS BITOR(ValidateContentAndValue, ValidateException, ValidateComplete)
ENCODING InputRoot.Properties.Encoding
CCSID CCSIDCode
SET 'MyMessageSet'
FORMAT 'XML1');
END;
|
An exception is thrown but its catched externally and not by the HANDLE ERROR.
If you see the code there is a commented throw clause and when its uncommented the handle is activated. However, for parse its not.
Someone know how to accomplish this?
I'm using WMB 6.1.0.3 (not updated to 6.1.04 yet).
Thanks for any help. |
|
Back to top |
|
 |
fabyos |
Posted: Tue Jun 23, 2009 6:21 am Post subject: |
|
|
Apprentice
Joined: 15 May 2009 Posts: 37
|
There is a way to catch the ExceptionList that caused the catch on DECLARE...HANDLER statement?
The docs says that the DECLARE HANDLER absorbs the exception and this prevents the rollback by input node, if desired use RESIGNAL or THROW clause.
If used the last option than the exception list is "visible", but I dont wanna rollback, just log the error preciselly. There is a way to accomplish this?
If this exception occur I dont wanna to reprocess it again, just mark it as error. |
|
Back to top |
|
 |
mgk |
Posted: Tue Jun 23, 2009 7:29 am Post subject: |
|
|
 Padawan
Joined: 31 Jul 2003 Posts: 1642
|
Hi, this looks like it should work, so you should raise a PMR to investigate further... _________________ 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 |
|
 |
fabyos |
Posted: Tue Jun 23, 2009 8:51 am Post subject: |
|
|
Apprentice
Joined: 15 May 2009 Posts: 37
|
mgk wrote: |
Hi, this looks like it should work, so you should raise a PMR to investigate further... |
Hi, I forgot to mention on my last post after some redeploy and reset it worked, but I dont know why...
Now I'm trying to get the exception on handler, but I think that its not possible... |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
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
|
|
|
|