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:
Zac Shields
Past 24 Hours:
1
Prev. 24 Hours:
1
Overall:
5210
People Online:
Visitors:
329
Members:
0
Total:
329
Online Now:
New Topics
Lawson S3 HR/Payroll/Benefits
Post Tax Benefit Plan Table
11/14/2024 9:16 PM
Hi, totally new to Laswon. I have a repor
Lawson S3 Procurement
ED501 Error: Map 850 not supported by /law/c15vda/lawson/test10/edi/bin/laws_out_91
11/12/2024 3:47 PM
Tried runnning ED501 and getting the atathced erro
Lawson S3 HR/Payroll/Benefits
Error
11/6/2024 9:54 PM
When I try to enroll a retiree in 72.1 health plan
Infor ERP (Syteline)
Syteline: New Data Maintenance Wizard (Error) Need help
11/1/2024 4:24 PM
Hi, I need help with an error on syteline while us
Dealing with Lawson / Infor
Implementing Lawson v10 with Cerner Surginet, Case Cart Picking, and Quick Adds for the OR
10/29/2024 4:20 PM
Hi Everyone, I am wondering if there is any org
Lawson S3 HR/Payroll/Benefits
Canada Tax Calculation (Federal and Provincial) Issue
10/23/2024 5:00 AM
Initially, we had problem with CPP2 calculation is
Lawson S3 HR/Payroll/Benefits
CA Section 125 401k Plan
10/22/2024 10:13 PM
Does anyone have any recommendations on how to fac
S3 Systems Administration
Running AC120 deleted records from ACMASTER table
10/22/2024 3:40 PM
We recently ran the AC120 as normal and somehow it
Lawson S3 Procurement
RQ13 Approval Info
10/17/2024 2:12 PM
When a Requisition is approved on RQ13, what table
S3 Customization/Development
Read and Write CSV file COBOL
10/9/2024 2:53 PM
Does anyone have a quik example of a program that
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
1372
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
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
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
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
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
Hi Kyle.
No! I didn't think I could do that via JavaScript. That worked. Fantastic! Thanks!!!!!!
Please
login
to post a reply.