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 IndexWebSphere Message Broker SupportUnable to parse the XML inside the CData Section

Post new topicReply to topic
Unable to parse the XML inside the CData Section View previous topic :: View next topic
Author Message
muthu121521
PostPosted: Mon Jan 25, 2021 7:01 am Post subject: Unable to parse the XML inside the CData Section Reply with quote

Apprentice

Joined: 31 Aug 2015
Posts: 35

We are having an issue with with one of the C DataSection as below

Quote:
![CDATA[<
<address1>1036</address1>
<address2>PA &quot;5TH&quot; ST</NS1:address2>
<Employment>
<Employmentpn AddressLine1="47A LEE DR" AddressLine2="LEE PA" AppIndex="1" Employer="ABC &quot;ABC123&quot; XYZ" ZipCode="107086-0000"/>
</Employment>
>]]>


When i parse the above cdata section in IIB i am able to get the address 2 field as PA "5TH" ST


But the Employer Attribute inside the Employment Tag coming only as
Employer="ABC &quot;ABC123&quot; XYZ"


How do we parse the attributes inside the field
Back to top
View user's profile Send private message
Vitor
PostPosted: Mon Jan 25, 2021 8:05 am Post subject: Re: Unable to parse the XML inside the CData Section Reply with quote

Grand High Poobah

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

muthu121521 wrote:


But the Employer Attribute inside the Employment Tag [b]coming only as
Employer="ABC &quot;ABC123&quot; XYZ"


So, to be clear, you're parsing this CDATA section using ESQL. The escaped characters are being correctly converted if they're the content of a tag, but are not being converted if the escape occurs within the text of a attribute.

Do I have that correct?

If so, please post the PARSE statement that you're using along with the version of IIB.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
muthu121521
PostPosted: Tue Jan 26, 2021 8:49 am Post subject: Reply with quote

Apprentice

Joined: 31 Aug 2015
Posts: 35

Code:

DECLARE inCCSID INT InputProperties.CodedCharSetId;                     
DECLARE inEncoding INT InputProperties.Encoding;      
CREATE LASTCHILD OF OutputRoot DOMAIN 'XMLNSC'          PARSE(InputRoot.XMLNSC.ns1:Response.SubmitResult, inEncoding, inCCSID);


IIB Version is 10.0.0.11

I have an IIB ACE Version 11.0.0.9 in my Local laptop as well, Even I have tried there as well but the same result
Back to top
View user's profile Send private message
timber
PostPosted: Thu Jan 28, 2021 4:03 am Post subject: Reply with quote

Grand Master

Joined: 25 Aug 2015
Posts: 1162

Please can you supply
- the input XML document (remove anything confidential, obviously)
- the output of a Trace node showing the contents of the message tree
Back to top
View user's profile Send private message
Display posts from previous:
Post new topicReply to topic Page 1 of 1

MQSeries.net Forum IndexWebSphere Message Broker SupportUnable to parse the XML inside the CData Section
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.