-
Example for calling procedure
Give an example for calling procedure with user and system exception
-
PL/SQL Block output
begin For i in 1..5 loop insert into A values(i); savepoint 1; end loop; rollback to savepoint 1; commitend;--initially there are no data in table A. So my question is after execution of this block what should be the data present in table A?
-
-
Write the order of precedence for validation of a column in a table ?
I. done using Database triggers. ii. done using Integarity Constraints. I & ii. Exception :
-
-
What are the components of a PL/SQL Block ?
Declarative part, Executable part and Exception part. Datatypes PL/SQL
-
-
-
-
-
-
-
-
-
What is Overloading of procedures ?
The Same procedure name is repeated with parameters of different datatypes and parameters in different positions, varying number of parameters is called overloading of procedures. e.g. DBMS_OUTPUT put_line What is a package ? What are the advantages of packages ?
-
Give the structure of the procedure ?
PROCEDURE name (parameter list.....) is local variable declarations BEGIN Executable statements. Exception. exception handlers end;
-
What are the two parts of a procedure ?
Procedure Specification and Procedure Body.
-
Where the Pre_defined_exceptions are stored ?
In the standard package. Procedures, Functions & Packages ;
-
What are two virtual tables available during database trigger execution ?
The table columns are referred as OLD.column_name and NEW.column_name.For triggers related to INSERT only NEW.column_name values only available.For triggers related to UPDATE only OLD.column_name NEW.column_name values only available.For triggers related to DELETE only OLD.column_name values only available.
-
Explain the two type of Cursors ?
There are two types of cursors, Implicit Cursor and Explicit Cursor.PL/SQL uses Implicit Cursors for queries.User defined cursors are called Explicit Cursors. They can be declared and used.
PL/SQL Interview Questions
Ans