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
  • 1.  comparing document lists

    Posted Sun October 18, 2009 07:43 PM

    Hi,

    could anyone of you please let me know how to compare variables in two document lists. the structure is as below.

    doc1
    —list1
    -----sourcename
    -----fieldname
    -----fieldvalue
    doc2
    —list2
    -----sourcename
    -----fieldname
    -----fieldvalue

    my requirement is like to perform some transactions if sourcename and fieldvalue of both the docs are same.

    Please let me know how to solve this.

    Thanks in advance.


    #Integration-Server-and-ESB
    #webMethods
    #Flow-and-Java-services


  • 2.  RE: comparing document lists

    Posted Mon October 19, 2009 09:59 PM

    Hi Raj,
    Initially u need to pull then in a loop then u can compare fields. under the loop u can mention a branch and sequence condition . Or you can use some of the java utilities of string compare.

    flow is here

    loop on first document
    loop on second document
    branch on ( with no condition & evaluate labels true)
    sequence : doc1/sourcename == doc2/sourcename
    sequence : doc1/fieldname == doc2/fieldname


    #Flow-and-Java-services
    #Integration-Server-and-ESB
    #webMethods


  • 3.  RE: comparing document lists

    Posted Tue October 20, 2009 04:35 PM

    Hi,

    Thanks for your reply.

    Is it possible to compare the two values in same step, instead of having two sequence steps?

    Thanks in advance


    #Integration-Server-and-ESB
    #webMethods
    #Flow-and-Java-services


  • 4.  RE: comparing document lists

    Posted Tue October 20, 2009 05:03 PM

    Hi,

    The problem solved.

    Loop over doc1\list1
    –loop over doc2\list2
    — branch (evaluate lable set to true)
    ----(%doc1\list1\source%==%doc2\list2\source% && %doc1\list1\value%==%doc2\list2\value%):sequence

    Thanks.


    #webMethods
    #Flow-and-Java-services
    #Integration-Server-and-ESB