The WHILE/LOOP construct is used to iteratively execute DGL statements. The execution of statements is determined by evaluation of the boolean_expression.
The statements are executed until the expression evaluates to false. For example,
The statements between the keywords LOOP and END LOOP are executed as long as a is greater than b.
Assume that b changes its value inside the loop and in one of the iterations the expression a > b becomes false. In the next iteration, the expression is examined and, since a > b is now false, the execution of template statements continues with the first statement after the END LOOP.