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 » Searching an XML message based on attribute

Post new topic  Reply to topic
 Searching an XML message based on attribute « View previous topic :: View next topic » 
Author Message
sandeep.nandanwar
PostPosted: Mon Mar 09, 2015 12:54 am    Post subject: Searching an XML message based on attribute Reply with quote

Novice

Joined: 21 Jan 2015
Posts: 13

I am new to ESQL.

I have the following message and I want to check if the number of occurences of CustomerContactList, CustomerId, etc. Depending on number of occurences i want to process it further.


Code:
<getCustomerIDsReturn xsi:type="xsd:string"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
<CustomerList1>
    <Customer CustomerID="66" CustomerType="0223" ExternalCustomerID="123"
        OrganizationCode="ABCDE" Status="10">
        <Extn Status="0"/>
        <CustomerContactList>
            <CustomerContact CustomerContactID="100000" Status="10"/>
            <CustomerContact CustomerContactID="66"/>
            <CustomerContact CustomerContactID="100008"/>
        </CustomerContactList>
    </Customer>
    <Customer CustomerID="100000240" CustomerType="0223"
        ExternalCustomerID="123" OrganizationCode="ABCDE">
        <Extn Status="0"/>
        <CustomerContactList>
            <CustomerContact CustomerContactID="123"/>
        </CustomerContactList>
    </Customer>
</CustomerList1>]]></getCustomerIDsReturn>


It would be really grateful if someone could help.

Thanks in Advance
-SSN
Back to top
View user's profile Send private message
New_2_IIB9
PostPosted: Mon Mar 09, 2015 2:06 am    Post subject: Reply with quote

Newbie

Joined: 17 Dec 2014
Posts: 6

use Cardinality Function in esql

http://www-01.ibm.com/support/knowledgecenter/SSKM8N_8.0.0/com.ibm.etools.mft.doc/ak05530_.htm
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Mon Mar 09, 2015 4:12 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

You are dealing with a CData field. I guess you would have to extract the value and parse it...
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Searching an XML message based on attribute
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.