Table of Contents

About

Performs the specified action (exits SQL*Plus by default) if an operating system error occurs (such as a file writing error).

In iSQL*Plus, performs the specified action (stops the current script by default) and returns focus to the Workspace if an operating system error occurs.

Syntax

WHENEVER OSERROR 
    { 
    EXIT [SUCCESS|FAILURE|n|variable|:BindVariable] [COMMIT|ROLLBACK] 
    | 
    CONTINUE [COMMIT|ROLLBACK|NONE]
    }

where:

  • you must choose the EXIT or CONTINUE statement
  • the block [SUCCESS|FAILURE|WARNING|n|variable|:BindVariable] define the exit code that can be:
  • the block [COMMIT|ROLLBACK] defines the transaction termination action to do.