Download PL/SQL User's Guide and Reference
Transcript
EXIT Statement EXIT; END IF; END; -- not allowed; use RETURN instead The following loop normally executes ten times, but it will exit prematurely if there are less than ten rows to fetch: FOR i IN 1..10 LOOP FETCH c1 INTO emp_rec; EXIT WHEN c1%NOTFOUND; total_comm := total_comm + emp_rec.comm; END LOOP; The following example illustrates the use of loop labels: <<outer>> FOR i IN 1..10 LOOP ... <<inner>> FOR j IN 1..100 LOOP ... EXIT outer WHEN ... END LOOP inner; END LOOP outer; -- exits both loops Related Topics Expressions, LOOP Statements PL/SQL Language Elements 13-51
Related documents
PL/SQL User's Guide and Reference
Oracle Database PL/SQL User's Guide and Reference
PL/SQL User's Guide and Reference, Release 8.0
SQL*Loader Control File
A Software Application for a Car Sales and Servicing
Automated bookmark management
Migration Center User`s Manual
Peg Perego Prima Pappa Diner User's Manual
ソフトウェア工学
What is iSQL*Plus? - Oracle Documentation
Database Link User`s Manual