What is the difference between ITER and DO ? I know both are
used to execute set of statements repeatedly, but what is the
main difference?

Answers were Sorted based on User's Feedback



What is the difference between ITER and DO ? I know both are used to execute set of statements rep..

Answer / joy mukherjee

There is no comparision between DO and ITER as DO statement
is an looping statement and ITER is an branching statement
like LEAVE.
When I use ITER with some condition inside a DO-ENDDO loop,
when that condition occouerd, ITER transfered the control
to ENDDO not out of the loop like LEAVE ie it just skip the
excecution of statements between ITER and ENDDO.

In one statement we can say that ITER in RPGLE is same as
CONTINUE in C.

Is This Answer Correct ?    27 Yes 1 No

What is the difference between ITER and DO ? I know both are used to execute set of statements rep..

Answer / chittim

with in a do loop itself again we have to create loop again
where u want loop by using iterate.

Is This Answer Correct ?    2 Yes 9 No

Post New Answer

More RPG400 Interview Questions

what is the equivalent keyword for CHAIN opcode ??

7 Answers   TCS,


what is the difference between SETON RT & RETURN?

5 Answers  


Setps to create .csv file on IFS folder in AS/400( V4R3)....?

3 Answers   TCS,


1.Coding in cl to send an message? 2..What is turnover and use? What are the different levels?

4 Answers   IBM,


can any body correct the following code? Following a procedure which returns the maximum of two numbers.Correct the following code. P GETMAX B D GETMAX PI D NUM1 35 0 D NUM2 45 0 C IF NUM1 > NUM2 C RETURN NUM1 C ELSE C RETURN NUM2 C ENDIF P GETMAX E

1 Answers  


What are different ways to pass data between programs and which one is the efficient way?

5 Answers  


How can we change element of compile time array?Can we do so

1 Answers   TCS,


Why we need to give File and To file Names While we are using OVRDBF. What is your understanding related to this?

2 Answers   Cap Gemini,


Need a sql query: retrive all duplicate records in table

3 Answers  


what is program status data structure?

1 Answers   IBM,


what is file information data structure?

1 Answers   IBM,


How do you find out whether a record is present in the physical file without reading the file? for Example Employee No: 100 in an Employee master.How do we find out whther 100 is present in Employee master without reading the file?

11 Answers   Bank Of America, CSC, IBM,


Categories