Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
26
Task/Jump-anywhere/PL-SQL/jump-anywhere.sql
Normal file
26
Task/Jump-anywhere/PL-SQL/jump-anywhere.sql
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
DECLARE
|
||||
i number := 5;
|
||||
divide_by_zero EXCEPTION;
|
||||
PRAGMA exception_init(divide_by_zero, -20000);
|
||||
BEGIN
|
||||
DBMS_OUTPUT.put_line( 'startLoop' );
|
||||
<<startLoop>>
|
||||
BEGIN
|
||||
if i = 0 then
|
||||
raise divide_by_zero;
|
||||
end if;
|
||||
DBMS_OUTPUT.put_line( 100/i );
|
||||
i := i - 1;
|
||||
GOTO startLoop;
|
||||
EXCEPTION
|
||||
WHEN divide_by_zero THEN
|
||||
DBMS_OUTPUT.put_line( 'Oops!' );
|
||||
GOTO finally;
|
||||
END;
|
||||
<<endLoop>>
|
||||
DBMS_OUTPUT.put_line( 'endLoop' );
|
||||
|
||||
<<finally>>
|
||||
DBMS_OUTPUT.put_line( 'Finally' );
|
||||
END;
|
||||
/
|
||||
Loading…
Add table
Add a link
Reference in a new issue