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

Actual parameters into an XPath expression.

  • 1.  Actual parameters into an XPath expression.

    Posted Wed July 05, 2006 05:39 PM

    Hi, I’m working on a function that receives XML tags and insert the actual parameter into an XPath expressions to retrieve documents with those tags.
    The problem is that if I use the parameter to move the context node ( / ) the query works, but I need to insert it like an option ( […] )

    So:

    for $d in doc(“blabla.xml”)//tag/tag2/$actualparameter <— this works
    for $d in doc(“blabla.xml”)//tag/tag2[$actualparameter] <— this doesn’t work

    I think that the actual parameter contains elements, so it’s the same if I write:

    for $d in doc(“blabla.xml”)//tag/tag2/A
    (works)

    or

    for $d in doc(“blabla.xml”)//tag/tag2[A]
    (doesn’t work)

    What can I do?
    Thank you and sorry for my english :wink:


    #webMethods
    #API-Management
    #Tamino