Reputation: 1935
Where can I find Full list of all Predefined ORACLE PL/SQL Exceptions?
I have looked at that SQLCODE:-942 and SQLCODE:-02289 are exception code for sequence and table not existed. but whatever I cannot find any official document to explain the above two error code. so question is are these oracle Predefined exceptions? because I want to use the two error code to catch this two type exceptions.
Upvotes: 2
Views: 2608
Reputation: 461
http://docs.oracle.com/cd/B19306_01/appdev.102/b14261.pdf , this is the Oracle database PL/SQL Language reference manual, look for predefined PL/SQL exceptions..
Upvotes: -1
Reputation: 50017
You used the term 'exceptions', but it looks like you're asking about error code values, and specifically SQLCODEs. I'll try to answer both questions. :-)
To find the pre-defined exceptions defined in the database you can look in the package SYS.STANDARD. This is where the standard exceptions, such as NO_DATA_FOUND and TOO_MANY_ROWS, are defined. This is a good place to look if you're interested in trapping a specific SQLCODE as it might save you having to define a custom exception and initializing it with PRAGMA EXCEPTION_INIT
.
To find a complete list of error code values, including SQLCODEs, compiler errors, etc, you should look in the version of the Oracle Database Error Messages manual for the database version you're using. In his reply above, @Mat gives a reference to the 11.1 manual. The 11.2 manual can be found here.
Share and enjoy.
Upvotes: 3
Reputation: 43533
The closest thing I could find is a 10g PDF. The only error codes list I could find for 11g is an HTML document. It's totally weird to me that neither list includes the ORA-00942 code, although it's pretty self explanatory.
Upvotes: 1