|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Required fields to an error queue or continue processing |
« View previous topic :: View next topic » |
Author |
Message
|
LH33 |
Posted: Fri Feb 21, 2003 10:29 am Post subject: Required fields to an error queue or continue processing |
|
|
Master
Joined: 21 Nov 2002 Posts: 200
|
HI!
I have a message flow that needs to check for the existance of data in a tag. If the data is missing or null, I need to put a messge on an error queue. If the fields are there, then I need to continue to the next node in the flow. My code so far is:
IF (InputRoot.XML.CreateJob.DataArea.Job.AgencyCode IS NULL) or
(InputRoot.XML.CreateJob.DataArea.Job.AgencyCode= ' ') THEN
THROW USER EXCEPTION MESSAGE 2951 VALUES('MISSING AGENCY CODE')
What I want to do is format a XML error message and put it on a queue. How do I code the node to put the error on a queue or if everrything is okay, to just continue to the next node?
Thanks in advance for any help you can provide!!! LisaB |
|
Back to top |
|
 |
kirani |
Posted: Fri Feb 21, 2003 12:00 pm Post subject: |
|
|
Jedi Knight
Joined: 05 Sep 2001 Posts: 3779 Location: Torrance, CA, USA
|
Lisa,
Use a Filter node to do this,
First check for the existance of data in a tag using the esql code.
Code: |
IF (Body.CreateJob.DataArea.Job.AgencyCode IS NULL) or (Body.CreateJob.DataArea.Job.AgencyCode= ' ') THEN
return FALSE;
ELSE
return TRUE;
END IF;
|
Attach a new compute node to the false terminal of your Filter node, which will construct the "Error message", this message will be put on the Error queue using MQOutput node.
Attach the True terminal of your Filter node to other nodes for further processing.
I hope this helps. _________________ Kiran
IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries
|
|
Back to top |
|
 |
LH33 |
Posted: Fri Feb 21, 2003 12:03 pm Post subject: |
|
|
Master
Joined: 21 Nov 2002 Posts: 200
|
Kiran,
Thank you so much!!!
LisaB |
|
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
|
|
|
|