Login
Register
Search
Home
Forums
Jobs
LawsonGuru
LawsonGuru Letter
LawsonGuru Blog
Worthwhile Reading
Infor Lawson News Feed
Store
Store FAQs
About
Forums
Integration / Customization
IPA/ProcessFlow
Data Iterator
Home
Forums
Jobs
LawsonGuru
LawsonGuru Letter
LawsonGuru Blog
Worthwhile Reading
Infor Lawson News Feed
Store
Store FAQs
About
Who's On?
Membership:
Latest:
BDell92
Past 24 Hours:
0
Prev. 24 Hours:
0
Overall:
5275
People Online:
Visitors:
386
Members:
0
Total:
386
Online Now:
New Topics
Lawson S3 Financials
Applying credits to open AP invoices
4/28/2025 1:26 PM
Hello, I am new to the Lawson system and after ru
Lawson S3 Financials
Lawson APIA
4/28/2025 1:22 PM
Has anybody recently installed Lawson's APIA m
Lawson S3 Procurement
Tolerance Settings
3/31/2025 2:01 PM
I've been trying to set a tolerance for some t
Dealing with Lawson / Infor
Printing Solutions other than MHC
3/27/2025 1:00 PM
What are others using for printing solutions besid
Lawson S3 Procurement
Green check marks in Lawson 9.0.1
3/20/2025 4:55 PM
Hi, How to remove green check mark on items when o
Lawson S3 HR/Payroll/Benefits
Pay Rate History to Show All Positions
2/26/2025 3:34 PM
Does anyone know how to modify payratehistory.htm
Infor CloudSuite
How to build a Pre-Prod tenant
2/7/2025 1:28 AM
After we finished our implementation and ended our
Lawson S3 Procurement
Browser issue with RQC Shopping
1/28/2025 5:49 PM
Since the recent Chrome/Edge updates, our RQC shop
Lawson S3 Procurement
S3-Procurement New Company
1/22/2025 10:38 PM
My Accounting Department has created a new Company
S3 Customization/Development
JUSTIFIED RIGHT
1/15/2025 7:41 PM
Is there a way in Lawson COBOL to make a character
Top Forum Posters
Name
Points
Greg Moeller
4184
David Williams
3349
JonA
3291
Kat V
2984
Woozy
1973
Jimmy Chiu
1883
Kwane McNeal
1437
Ragu Raghavan
1375
Roger French
1315
mark.cook
1244
Forums
Filtered Topics
Unanswered
Unresolved
Announcements
Active Topics
Most Liked
Most Replies
Search Forums
Search
Advanced Search
Topics
Posts
Prev
Next
Forums
Integration / Customization
IPA/ProcessFlow
Data Iterator
Please
login
to post a reply.
5 Replies
0
Subscribed to this topic
52 Subscribed to this forum
Sort:
Oldest First
Most Recent First
Author
Messages
Erin
Advanced Member
Posts: 24
9/14/2013 1:33 AM
Is there a way of resetting the _nextPosition in a Data Iterator?
I have an IPA that reads in two variables that are passed in from another IPA flow that represents two separate but similarly formatted files.
I have a generic variable "inputFileName" in my IPA that I set to the first of the two incoming file variables (e.g. inputFileName = FileA.txt)
At the end of the FileA.txt file processing I use a branch to see what the inputFileName is set to in order to see if it is already set to the second file FileB.txt (so I can either end the job if already FileB.txt or know I have to reassign the inputFileName to FileB.txt).
But I've noticed that it loops through the FileA.txt beautifully, it sees after the last record is read that I am on the first file and reassigns inputFileName to "FileB.txt", reads in the correct number of record and then moves to the Data Integrator again. But the Data Integrator ends abruptly. I think it is because the DI_nextPosition = 93659 and hits end of stream.
If there is another way to reuse the Data Iterator loop for more than one file, and I am just being stupid as how to do it please let me know (my feelings won't get hurt).
Woozy
Veteran Member
Posts: 709
9/16/2013 3:27 PM
Split
Hi Erin,
Maybe I'm not following you. Are you trying to use the same node to process both files without ever exiting the loop? I think that would be problematic. I don't think IPA will allow you to override the nextPosition value. Why wouldn't you use separate nodes - one for FileA and one for FileB? I realize this would require you to create and assign variables for all of the fields returned from each file, but I think you'd be better off. With some creativity you could use the same nodes within the loops, but just branch to the correct di-end node based on the filename.
Maybe it would help if you would attach a sample of your flow that just includes the relevant nodes so we can see what you're doing?
Kelly
Erin
Advanced Member
Posts: 24
9/18/2013 4:45 PM
Split
Hi Woozy,
Sorry I confused you. I do exit the Iterator loop (when the first file get to the end). After the ITEnd node exit it comes out and goes to an Assign node so I reassign the input file name to the second incoming file. Then I read in that file and connect back to the DATAIT node so I can use all the same nodes all over again for the second file since the files contain the same format.
Of course in .Net or any other language this certainly wouldn't be an issue but since I need the file names passed in from another IPA, I am trying to do it in IPA. I don't know what resets the pointer as I assumed the ITEnd did that automatically.
Kyle Jorgensen
Veteran Member
Posts: 122
9/18/2013 5:23 PM
Split
Have you tried using a javascript expression in an assign node to set 'iteratornodeName_nextPosition' to zero before you loop back to it for it's second use?
Kyle Jorgensen
Veteran Member
Posts: 122
9/18/2013 5:36 PM
Split
I just tried testing my idea. It works. Set the nextPosition value to zero before you loop back into the iterator for your 2nd go 'round.
Erin
Advanced Member
Posts: 24
9/18/2013 7:35 PM
Split
Hi Kyle.
No! I didn't think I could do that via JavaScript. That worked. Fantastic! Thanks!!!!!!
Please
login
to post a reply.