Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: ORACLE error codes

Re: ORACLE error codes

From: -=< a q u a b u b b l e >=- <aquabubble_at_Remove.No.Parma.Ham.Remove.geocities.com>
Date: Sun, 24 Oct 1999 17:10:36 +0100
Message-ID: <7uvb37$9i7$1@uranium.btinternet.com>


Alex Vinokur <alexander.vinokur_at_telrad.co.il> wrote in message news:7uv06i$9vu$1_at_nnrp1.deja.com...
> In article <7uuoo4$fh9$1_at_neptunium.btinternet.com>,
> "-=< a q u a b u b b l e >=-"
> <aquabubble_at_Remove.No.Parma.Ham.Remove.geocities.com> wrote:
> [snip]
>
> > Why do you want to code for every error? Why don't you find the ones
> you
> > expect, and then code for WHEN OTHERS, finding out the error code and
> error
> > message using SQLERRM, etc.?
> >
> > HTH
> >
> >
>
> 1. I don't want to use hard code (1403).
> I'd prefer to use errors' mnemonic codes.
> 2. There is no problem to create enum containing such codes.
> 3. I'd prefer to use standard header file containing such
> mnemonic codes.
>
> Thanks
> Alex

Okay, well there are PL/SQL predefined exceptions that are defined in the STANDARD package. These are documented in Oracle's PL/SQL User's Guide and Reference, which you can find on TechNet at:

http://technet.oracle.com/doc/server.815/a67842/06_errs.htm

There are only about 20-30, which are:

ACCESS_INTO_NULL
COLLECTION_IS_NULL
CURSOR_ALREADY_OPEN

DUP_VAL_ON_INDEX
INVALID_CURSOR
INVALID_NUMBER

LOGIN_DENIED
NO_DATA_FOUND
NOT_LOGGED_ON
PROGRAM_ERROR
ROWTYPE_MISMATCH
SELF_IS_NULL
STORAGE_ERROR

SUBSCRIPT_BEYOND_COUNT
SUBSCRIPT_OUTSIDE_LIMIT
SYS_INVALID_ROWID
TIMEOUT_ON_RESOURCE
TOO_MANY_ROWS
VALUE_ERROR
ZERO_DIVIDE Any others you will have to define youself.

HTH Received on Sun Oct 24 1999 - 11:10:36 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US