Thank you for supporting the Cloud Customer Connect Community in 2024. It's a gift to work with you!

Look back
You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

Using predicate with a variable to iterate through nodes in a while loop

edited Jun 20, 2019 12:51AM in Integration 2 comments

Summary

Using predicate with a variable to iterate through nodes in a while loop

Content

We need to process a flat file using NXSD. The file structure contains a lot of invoice headers and invoice details that are in one sequence and not nested, and therefore OIC cannot use a for-each loop to process them.

I'm trying to iterate them by using a count nodes function on the details to populate a variable called $DetailsCount with the number of the details and then use a while loop to iterate through the details and map the fields of each detail element using a predicate with the index which is $Rowcount: nssrcmpr:Read/nsmpr1:BatchRecord/nsmpr1:InvoiceDetails[$Rowcount]/nsmpr1:ORDCOD 

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!