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 error

Post new topic  Reply to topic
 parsing error « View previous topic :: View next topic » 
Author Message
alapati
PostPosted: Sun Apr 08, 2012 11:21 pm    Post subject: parsing error Reply with quote

Newbie

Joined: 08 Apr 2012
Posts: 9

I need to test my flow with sample message provided by my client.but that sample message doesn't having name space. so i getting exception as xml parsing errors have occurred when trying to validate the message.
Back to top
View user's profile Send private message
mapa
PostPosted: Mon Apr 09, 2012 12:47 am    Post subject: Reply with quote

Master

Joined: 09 Aug 2001
Posts: 257
Location: Malmö, Sweden

Is the XML well-formed?

Verify that first.

Then provide more details so your question is understandable and possible to answer.
Back to top
View user's profile Send private message Visit poster's website
alapati
PostPosted: Mon Apr 09, 2012 1:03 am    Post subject: Reply with quote

Newbie

Joined: 08 Apr 2012
Posts: 9

Ya Xml is well formed . am using xmlnsc as a domain parser and using related xsd only. when giving validate option as content and value or content then only its getting exception. if anything else please let me know.
Back to top
View user's profile Send private message
mapa
PostPosted: Mon Apr 09, 2012 1:32 am    Post subject: Reply with quote

Master

Joined: 09 Aug 2001
Posts: 257
Location: Malmö, Sweden

OK, that is more precis information.
If you don't use the validation the broker parse the message fine then?

Using the toolkit you can validate a XML file against its schema. What does it say if you try that?

What parser exception does the broker report?
Back to top
View user's profile Send private message Visit poster's website
alapati
PostPosted: Mon Apr 09, 2012 1:45 am    Post subject: Reply with quote

Newbie

Joined: 08 Apr 2012
Posts: 9

Ya without using validation/validate option as none then xml is parsed successfully.

xml file against its schema means test the xml with another schema file which is not related to this?
Back to top
View user's profile Send private message
mapa
PostPosted: Mon Apr 09, 2012 3:06 am    Post subject: Reply with quote

Master

Joined: 09 Aug 2001
Posts: 257
Location: Malmö, Sweden

No, you have one or more XSD already.
Use them in the toolkit, don't remember if you need to also switch eclipse perspective as well. Right click on the opened file and choose validate.
You must probably associate it with your schema first, don't remember if there is a menu option for that. Otherwise just add a xsi schema location.
Back to top
View user's profile Send private message Visit poster's website
Vitor
PostPosted: Mon Apr 09, 2012 4:40 am    Post subject: Re: parsing error Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

alapati wrote:
I need to test my flow with sample message provided by my client.but that sample message doesn't having name space. so i getting exception as xml parsing errors have occurred when trying to validate the message.


WMB can validate an XML document with no namespace with the XMLNSC domain. I'm looking at a flow that does that now.

If you mean that the sample supplied by your client doesn't have a namespace but the schema does, then WMB is right - the XML is invalid in that it doesn't match the schema.

If that's not what you mean take a user trace & see why WMB thinks the document is invalid.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
kimbert
PostPosted: Mon Apr 09, 2012 8:44 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Please quote the error message - in full. It's very hard to help without knowing what the problem is.
Back to top
View user's profile Send private message
alapati
PostPosted: Mon Apr 09, 2012 9:35 pm    Post subject: Reply with quote

Newbie

Joined: 08 Apr 2012
Posts: 9

Yes, the sample doesn't have a namespace but the schema does.So how can add a namespace to that sampe xml?
Back to top
View user's profile Send private message
smdavies99
PostPosted: Mon Apr 09, 2012 9:47 pm    Post subject: Reply with quote

Jedi Council

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

alapati wrote:
Yes, the sample doesn't have a namespace but the schema does.So how can add a namespace to that sampe xml?


go back to your client and tell them that the XML they have provided DOES NOT MATCH The Schema.
If they insist it is correct then get a signed waiver to this effect and move on. Don't validate against a schema you know to be faulty.

OR

You could change the schema to remove the namespace.
I'd also keep the existing schema/messageset around so that when the customer realises what they have done and they start sending you 'good' data you can swap the messageSets over and continue as if nothing happened with a 'I'm a really Smug Git' smile on your face.
_________________
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
Vitor
PostPosted: Tue Apr 10, 2012 4:38 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

alapati wrote:
Yes, the sample doesn't have a namespace but the schema does.So how can add a namespace to that sampe xml?


You could try XMLSpy or any other XML editor?

So how do you know that live XML will not omit the namespace as well? How do you know the schema shouldn't in fact have a namespace?
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
mapa
PostPosted: Tue Apr 10, 2012 4:59 am    Post subject: Reply with quote

Master

Joined: 09 Aug 2001
Posts: 257
Location: Malmö, Sweden

alapati wrote:
Yes, the sample doesn't have a namespace but the schema does.So how can add a namespace to that sampe xml?


Lots of guessing.

No namespace or just no namespace prefix but a default namespace?
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » parsing error
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.