Exit to a label
SQL> SQL> DECLARE 2 just_a_num NUMBER := 1; 3 BEGIN 4 <<just_a_loop>> 5 LOOP 6 dbms_output.put_line(just_a_num); 7 EXIT just_a_loop 8 WHEN (just_a_num >= 10); 9 just_a_num := just_a_num + 1; 10 END LOOP; 11 END; 12 / 1 2 3 4 5 6 7 8 9 10 PL/SQL procedure successfully completed. SQL>