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.



#Automation


#Applicationintegration
#webMethods
#Integration
 View Only
  • 1.  join within a collection

    Posted 02/04/05 08:23 PM

    I would appreciate any help with formulating a query joining documents within a collection.

    The documents are along the lines of the following:
    1.

    2.



    I’d like to be able to query for the second document by id, and then find the first document by joining the second’s idref to the first’s id.

    I’ve tried the following with no success:

    for $a in input()/entity
    where tf:getInoId($a) = 2
    return
    for $b in input()/ENTITY
    where $b[@id] = $a/SUBCLASS-OF[@idref]
    return
    $b


    #Tamino
    #API-Management
    #webMethods


  • 2.  RE: join within a collection

    Posted 02/07/05 04:05 PM

    Hi,

    In order to join the documents via the attributes ?idref? and ?id? you have to rewrite your join predicate:

    for $a in input()/entity
    where tf:getInoId($a) = 2
    return
    for $b in input()/ENTITY
    where $b/@id = $a/SUBCLASS-OF/@idref
    return
    $b

    Be sure that you have defined a standard index on the ?idref? attribute. Otherwise you will run into performance problems.

    Best Regards,

    Thorsten Fiebig


    #webMethods
    #Tamino
    #API-Management