Web Service NOde - Detect EOF marker

 1 Replies
 0 Subscribed to this topic
 52 Subscribed to this forum
Sort:
Author
Messages
TomD
Basic Member
Posts: 7
Basic Member
    I'm using the Web Service Node in the PFI. My WS returns one or more records in the XML data stream. How do I detect the last record or EOF so I know when to stop processing. In PFI WS node, you can access each data element from WS using the array (0). Is there a max array counter that the PFI tool provides for us to use?

    thanks,
    Tom.
    TomD
    Basic Member
    Posts: 7
    Basic Member
      I found the answer I needed it. WS returns a XML Object with one or multiple elements. To find out how many elements in the returned xmlOject, you would need to use the length() function. for example: xmlOject.length()
      This will return the max number of elements in your Oject. You would then create a JavaScript routine to loop through these elements to access your xml data fields returned from the WS. e.g. xmlOject::dataElement(x).