IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only

queryXmlNode attribute matching in WQL [EDITED]

  • 1.  queryXmlNode attribute matching in WQL [EDITED]

    Posted Wed March 10, 2010 05:44 PM

    EDIT: for some reason, the BBCode code tag strips off attributes from the package nodes in the example above. The package nodes should have the attributes type=“letter” and processed=“true”.

    Let’s say I have the following XML (a very simplified example):

    
    <packages>
    
    <package>Some package info</package>
    <package>Other package info</package>
    
    </packages>

    and that I want to use a queryXMLNode (WQL) to filter out any package elements that have the type attribute set to “letter” and the processed attribute set to “false”. What’s the proper way of doing this multiple-attribute-matching? A simple AND doesn’t seem to cut it.

    
    doc.packages[0].package(type='letter' AND processed='true')

    yields the same result as

    
    doc.packages[0].package(type='letter' I CAN WRITE ANYTHING HERE)

    which is null, or no match, regardless of what I enter after the first attribute condition. If I just match on a single attribute, as

    
    doc.packages[0].package(type='letter')

    it works fine.

    Thanks in advance for any enlightenment in this matter.[/u]


    #webMethods
    #Integration-Server-and-ESB
    #webMethods-General