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 » XML and non XML in msg

Post new topic  Reply to topic
 XML and non XML in msg « View previous topic :: View next topic » 
Author Message
francoisvdm
PostPosted: Mon Apr 10, 2006 3:11 am    Post subject: XML and non XML in msg Reply with quote

Partisan

Joined: 09 Aug 2001
Posts: 332

I'm receiving a msg with some text in the beginning, followed by a valid XML. Two scenarios:
1.If I know the length of the non XML portion before the XML portion, how do I strip it out and only pass the XML on to the rest of the msg flow?
2. If I do NOT know the length of the non XML portion, how do I do the same as above?

Thanks
_________________
If you do not know the answer or you get the urge to answer with "RTFM" or "Search better in this forum", please refrain from doing so, just move on to the next question. Much appreciated.

Francois van der Merwe
Back to top
View user's profile Send private message Send e-mail
jefflowrey
PostPosted: Mon Apr 10, 2006 3:16 am    Post subject: Re: XML and non XML in msg Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Francoisvdm wrote:
I'm receiving a msg with some text in the beginning, followed by a valid XML. Two scenarios:
1.If I know the length of the non XML portion before the XML portion, how do I strip it out and only pass the XML on to the rest of the msg flow?

First, receive the message as BLOB.
Second, use SUBSTRING to remove the non-xml portion.
Francoisvdm wrote:
2. If I do NOT know the length of the non XML portion, how do I do the same as above?

First, receive the message as BLOB.
Second, use POSITION to find the start of the XML, possibly looking for "<?xml".
Third, use SUBSTRING to remove the non-xml portion.

FOURTH, use an RCD node to establish that the data is now XML.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
wschutz
PostPosted: Mon Apr 10, 2006 3:16 am    Post subject: Re: XML and non XML in msg Reply with quote

Jedi Knight

Joined: 02 Jun 2005
Posts: 3316
Location: IBM (retired)

Francoisvdm wrote:
1.If I know the length of the non XML portion before the XML portion, how do I strip it out and only pass the XML on to the rest of the msg flow?
So how can you tell where the XML starts? There must be something to tell you how long the first part it, or perhaps a delimiter? (Or are you expecting the first "<" to be the delimiter?)
_________________
-wayne
Back to top
View user's profile Send private message Send e-mail AIM Address
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » XML and non XML in msg
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.