|Oracle® Database PL/SQL Language Reference
11g Release 1 (11.1)
|PDF · Mobi · ePub|
For instructions for reading the syntax diagrams in this chapter, see Oracle Database SQL Language Reference.
Each of these
CREATE statements has an optional
REPLACE clause. Specify
REPLACE to re-create an existing PL/SQL unit—that is, to change its declaration or definition without dropping it, re-creating it, and regranting object privileges previously granted on it. If you redefine a PL/SQL unit, the database recompiles it.
None of these
CREATE statements can appear in a PL/SQL block.
If you want to recompile an existing PL/SQL unit without re-creating it (without changing its declaration or definition), use one of the following SQL statements:
Two reasons to use an
ALTER statement are:
To explicitly recompile a stored unit that has become invalid, thus eliminating the need for implicit run-time recompilation and preventing associated run-time compilation errors and performance overhead.
To recompile a unit with different compilation parameters.
For information about compilation parameters, see PL/SQL Units and Compilation Parameters.
TYPE statement has additional uses. For details, see ALTER TYPE Statement.