Developer Reference : Data Access Methods : SQL Engine Reference : SQL Syntax Reference : LOOP
 
LOOP
Remarks
A LOOP statement repeats the execution of a block of statements.
It is allowed only in stored procedures and triggers.
Zen does not support the postconditional loop REPEAT... UNTIL.
Examples
The following example increments the variable vInteger by 1 until it reaches a value of 11 and the loop ends.
TestLoop:
LOOP
IF (:vInteger > 10) THEN
LEAVE TestLoop;
END IF;
SET :vInteger = :vInteger + 1;
END LOOP;
See Also
CREATE PROCEDURE
CREATE TRIGGER
IF