What is the basic structure of a Procedural Language/Structured Query Language (PL/SQL) block?

The basic structure of a PL/SQL block contains the following three sections:
a. Declaration —Defines and initializes the variables and cursors of the block
b. Execution —Manipulates the variables and cursors defined in the declaration section using the control flow statements
c. Exception  —Handles the exceptions raised during the program
A typical PL/SQL block structure is given as follows:
Declare
<variable>
<CONSTANTS>
<CURSORS>
begin
<control statements>
exception
<exception handling statements>
end;

0 comments:

Post a Comment

Blogger news