what is the difference between pragma exception_init and
raise_application_error



what is the difference between pragma exception_init and raise_application_error..

Answer / welcomeashwin

PRAGMA EXCEPTION_INIT allows to associate an Oracle error
number with the name of a user-defined error. Here you need
to defined user-defined exception before it is used in
PRAGMA EXCEPTION_INIT. There are two parameters: exception
name and error code.

RAISE_APPLICATION_ERROR allows to create meaningful error
msg.it works with un-named user defined exceptions. It
associates the number of the error with the text of the
error. Therefore, the user-defined exception does nat have a
name associated with it. There are three parameter:
err_number, err_msg, keep-err

Is This Answer Correct ?    40 Yes 4 No

Post New Answer

More SQL PLSQL Interview Questions

Why we use sql profiler?

0 Answers  


What is sql partition function?

0 Answers  


How to raise user-defined exception with custom sqlerrm ?

0 Answers  


when a procedure /package is getting invalidated?

4 Answers   TCS,


there are 2 variables called x and y ,x contains 1,2 and y contains 3,4 we have to swap the values from x to y and y to x with out using dummy variables and it can be done only by using a single statement ? how?

12 Answers   Oracle,


write a query filter the null value data following source? name age john 30 smith null null 24 sharp 35 i want output name age john 30 sharp 35

1 Answers   TCS,


Can we use pl sql in mysql?

0 Answers  


What is package in pl sql?

0 Answers  


What are the differences between implicit and explicit cursors?

0 Answers  


What are the triggers associated with image items?

0 Answers  


What is Difference Between Unique and Primary Key Constraints?

0 Answers   Wipro,


what are all types of user defined functions? : Sql dba

0 Answers  


Categories