MySQL Reference Manual for version 4.0.18.

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

18.1.9.5 ITERATE Statement

 
ITERATE label

ITERATE can only appear within LOOP, REPEAT, and WHILE statements. ITERATE means "do the loop iteration again."

For example:

 
CREATE PROCEDURE doiterate(p1 INT)
BEGIN
  label1: LOOP
    SET p1 = p1 + 1;
    IF p1 < 10 THEN ITERATE label1; END IF;
    LEAVE label1;
  END LOOP label1;
  SET @x = p1;
END



This document was generated by rdg (Feb 25 2004) using texi2html