What is the difference between iter and do?



What is the difference between iter and do?..

Answer / Nilesh Rai

In RPG400, both 'ITER' and 'DO' are looping constructs but they differ in their functioning. 'ITR' is used for sequential access to records within a file while 'DO' is used for repetitive operations without specific data structures or files.nn`ITER` uses a pointer to move from one record to the next, whereas `DO` executes a block of code repeatedly a specified number of times.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More RPG400 Interview Questions

What would be the effect on the field where reverse image, underline and high intensity?

7 Answers   IBM,


Whether a module can consists of many procedures or it can consist of subprocedures having a main procedure?If it is possible that it can contain many individual procedures than can we have different name for complete module and how do we call this module in main modul?

3 Answers   Steria,


I have 1000 records in a file. I would like to generate 10 identical reports from this record with same format (structure of records) how do I do this?

1 Answers   IBM,


How we will read call stack?

4 Answers  


explain sflclr, sflend, sfldlt, and sflcsrrrn?

1 Answers   IBM,


what is the rpg system?

1 Answers   IBM,


What is the difference Return and InLr?

3 Answers  


difference between CHAIN and READE?

8 Answers   HCL,


Hi friends, I am using a load all subfile , and currently i am in in the third page of the subfile , from third page i have selected a record and called some other program .on returning, subfile is being loaded from the frist page. so can any one kindly suggest me in retaining my third page after returning. i.e loading from third page.

7 Answers  


What is file identifier where we can use?

1 Answers  


When we have a file with Duplicate records and I want to read the unique record from the file. For example a file containing Emp Name as 'Ram' and there are 3 entries of it. So how to read a unique record from File?

1 Answers  


What is SFLNXTCHG keyword why it has used and where? Briefly explain with Example.

2 Answers   IBM,


Categories