7 3 BEGIN_LOOP

LANSA Technical

7.3 BEGIN_LOOP

The BEGIN_LOOP command is used in conjunction with the END_LOOP command to form a processing loop.

The loop formed is repeated the number of times specified by the FROM, TO and STEP parameters. Optionally a field can be nominated in the USING parameter which contains the value of the current iteration of the loop.

Refer to the END_LOOP command for more details and examples.

Also See

7.3.1 BEGIN_LOOP Parameters

7.3.2 BEGIN_LOOP Examples

 

 

  BEGIN_LOOP --- USING -------- *INTERNAL ----------------------> 

                                field name

 

            >--- FROM  -------- 1 ------------------------------> 

                                numeric value or field name

 

            >--- TO ----------- 9999999 ------------------------> 

                                numeric value or field name

 

            >--- STEP --------- 1 ------------------------------| 

                                non-zero numeric value (+ or -)