Exception :
22. What is an Exception ? What are types of Exception ?
Exception is the error handling part of PL/SQL block. The types are Predefined and user_defined. Some of Predefined execptions are. CURSOR_ALREADY_OPEN. DUP_VAL_ON_INDEX. NO_DATA_FOUND. TOO_MANY_ROWS. INVALID_CURSOR. INVALID_NUMBER. LOGON_DENIED. NOT_LOGGED_ON. PROGRAM-ERROR. STORAGE_ERROR. TIMEOUT_ON_RESOURCE. VALUE_ERROR. ZERO_DIVIDE. OTHERS.
23. What is Pragma EXECPTION_INIT ? Explain the usage ?
The PRAGMA EXECPTION_INIT tells the complier to associate an exception with an oracle error. To get an error message of a specific oracle error. e.g. PRAGMA EXCEPTION_INIT (exception name, oracle error number)
24. What is Raise_application_error ?
Raise_application_error is a procedure of package DBMS_STANDARD which allows to issue an user_defined error messages from stored sub-program or database trigger.
25. What are the return values of functions SQLCODE and SQLERRM ?
SQLCODE returns the latest code of the error that has occured. SQLERRM returns the relevant error message of the SQLCODE.
26. Where the Pre_defined_exceptions are stored ?
In the standard package.
Monday, November 1, 2010
Oracle: Exceptions
2:09 AM
Vipin
1 comments:
http://xicrontechnology.blogspot.com/
Post a Comment