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 » Parsing Errors Entire XML Message

Post new topic  Reply to topic
 Parsing Errors Entire XML Message « View previous topic :: View next topic » 
Author Message
dianmushkov
PostPosted: Thu May 09, 2013 5:55 am    Post subject: Parsing Errors Entire XML Message Reply with quote

Newbie

Joined: 09 May 2013
Posts: 9

Hi
Is there a way to get all parsing exception in following scenario

CREATE LASTCHILD OF InputLocalEnvironment.tempData[I] DOMAIN('XMLNSC')
PARSE(xmlString CCSID 1208 SET 'XMLExamplesMessageSet' TYPE 'Application'
OPTIONS parserOptions);


I got Text:CHARACTER:cvc-complex-type.2.4.e: Unexpected element. Element "MiddleName" is not one of the choices.

But there also other xml validation errors. How can I get a "list" of all those in one pass - is it possible and how?
Back to top
View user's profile Send private message
kimbert
PostPosted: Thu May 09, 2013 7:30 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Sorry - not possible.

When the document has started to diverge from the rules in the xsd, it is ( in general ) impossible to know which errors to issue. I know there are XML parsers that will do this - but when the xsd is complex they are making a bunch of assumptions about what the 'correct' errors should be.
Back to top
View user's profile Send private message
goffinf
PostPosted: Thu May 09, 2013 10:44 pm    Post subject: Re: Parsing Errors Entire XML Message Reply with quote

Chevalier

Joined: 05 Nov 2005
Posts: 401

dianmushkov wrote:
Hi
Is there a way to get all parsing exception in following scenario

CREATE LASTCHILD OF InputLocalEnvironment.tempData[I] DOMAIN('XMLNSC')
PARSE(xmlString CCSID 1208 SET 'XMLExamplesMessageSet' TYPE 'Application'
OPTIONS parserOptions);


I got Text:CHARACTER:cvc-complex-type.2.4.e: Unexpected element. Element "MiddleName" is not one of the choices.

But there also other xml validation errors. How can I get a "list" of all those in one pass - is it possible and how?


You probably have to do your own [business] validation before you parse. By *business* I mean all of the validation rules that allow you to confirm that the message is business process able (not just that it conforms to the brittle and limited constraint model of XML schema). You could do this in a number of ways, such as, in Java, in XSLT (possibly using schematron), in ESQL.

HTHs

Fraser.
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 » Parsing Errors Entire XML Message
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.