CONTINUE Statement in PL/SQL (Oracle 11g)

 

We -as developers- know that most programming languages have CONTINUE statement to skip to next iteration of the loop, but unfortunately we didn't have in Oracle, so we used to do workaround code to imitate CONTINUE functionality. Say we have the following loop code:

SET serveroutput ON

DECLARE

BEGIN

  FOR i IN 1 .. 10

  LOOP

    DBMS_OUTPUT.put_line ('The current number is ' || i);

  END LOOP;

END;

Subscribe to Saad Nayef's Personal Website RSS