Posted: Wed Aug 19, 2009 9:27 am Post subject: XML Field Validation
Apprentice
Joined: 17 Aug 2009 Posts: 36
I have a requirement to validate the contents of the XML file which comes through a MQInput Q.
MQInput Validation is enable for ‘Content and Value’ and 'exception'
The requirement is to identify the field in which the validation error occured and send a response message back to the sender.
Ie. If FIELD_A data item is missing, response message should go back as follows
Error in field : FIELD_A
Error Message : This is a compulsory field
If the validation is enable on the MQInout Q, is it possible to capture the field with the error. I know this is horrendous but this is the requirement.
Joined: 10 Feb 2003 Posts: 6076 Location: Somewhere over the Rainbow this side of Never-never land.
If you connect a TraceNode to the Failure terminal of the MQInput Node and set it up to output the ExceptionList the resulting output from processing an invlid message will show you what Kimbert means.
If the level of detail given in the ExceptionList (if you are using V6.1 & XMLNSC) should allow you to format the reply.
If it does not then I'm afraid that you will have to do the checking manually. _________________ 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.
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