what is mean by forward declaration and where we'll use it.

Answer Posted / venkat

A forward declaration looks like the package definition
part but is inside the bode.

e.g.

procedure A is
begin
B;
end A;

procedure B is
begin
null;
end B;

will not work, because during call to B B is still unknown
(1 Step compiler) therefore we need a forward declaration:

procedure B;

procedure A is
begin
B;
end A;

procedure B is
begin
null;
end B;


now we can compile

Is This Answer Correct ?    30 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a scalar value in sql?

806


What is a natural join?

733


How do I run a pl sql procedure in sql developer?

692


How to start the command-line sql*plus?

745


Difference between table function and pipelined function?

768






Is nosql relational?

707


explain normalization concept? : Sql dba

790


What packages are available to pl/sql developers?

811


Explain what is a subquery ?

852


Why does sql need a server?

760


How exception is different from error?

762


what are null values? : Sql dba

708


Is sql injection illegal?

771


Explain the the delete statements in sql?

756


Determine if oracle date is on a weekend?

767