les08 except tellme2





Handling Exceptions













The interactions in this eCourse require Javascript to be enabled.



 

Handling Exceptions: Part 2


previous|next





Syntax



EXCEPTION WHEN exception1 [OR exception2 . . .] THEN statement1; statement2; . . .







Is an optional exception-handling clause that traps any exceptions
that have not been explicitly handled





[WHEN exception3 [OR exception4. . .] THEN statement3; statement4; . . .] [WHEN OTHERS THEN statement5; statement6; . . .]



Guidelines for Trapping Exceptions

Begin the exception-handling section of the block with the EXCEPTION keyword.
Define several exception handlers, each with its own set of actions, for the block.
When an exception occurs, PL/SQL processes only one handler before leaving the
block.
Place the OTHERS clause after all other exception-handling clauses.
You can have only one OTHERS clause.
Exceptions cannot appear in assignment statements or SQL statements.








Is one or more PL/SQL or SQL statements












Is the standard name of a predefined exception or the name of a userdefined exception declared within the declarative section













Wyszukiwarka

Podobne podstrony:
les08 except tellme1
les08 except tellme3
les08 pack tellme1
les08 except showme
les08 except whylearnit
les08 man triggers tellme
les08 func cre tellme1
les08 func cre tellme2
les08 pack spec tellme
les08 cre block1 tellme
les08 cre block2 tellme
les08 audit trigger1 tellme
les08 proc cre tellme2
les08 cre anonymous1 tellme
les08 cre triggers tellme
les08 proc cre tellme1
les08 cre dmltriggers1 tellme
les08 pack body tellme
ExceptionDetailMessage

więcej podobnych podstron