Skip Headers
Oracle® Database PL/SQL Language Reference
11g Release 2 (11.2)

Part Number E10472-02
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Index
Index
Go to Master Index
Master Index
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
View PDF

Procedure

A procedure is a subprogram that performs a specific action.

You must declare and define a procedure before invoking it. You can either declare and define it at the same time, or you can declare it first and then define it later in the same block, subprogram, or package. A procedure invocation, or procedure call, is a statement.

Note:

Topics:

Syntax

procedure_declaration ::=

procedure_declaration
Description of the illustration procedure_declaration.gif

procedure_heading ::=

procedure_heading
Description of the illustration procedure_heading.gif

See parameter_declaration ::=.

procedure_definition ::=

procedure_definition
Description of the illustration procedure_definition.gif

See:

Semantics

body

The required executable part of the procedure and, optionally, the exception-handling part of the procedure.

declare_section

The optional declarative part of the procedure. Declarations are local to the procedure, can be referenced in body, and cease to exist when the procedure completes execution.

procedure_declaration

Declares a procedure, but does not define it. The definition must appear later in the same block, subprogram, or package as the declaration.

A procedure declaration is also called a procedure specification, or procedure spec.

procedure_definition

Either defines a procedure that was declared earlier or both declares and defines a procedure.

procedure_name

The name that you give to the procedure that you are declaring or defining.

Examples

Related Topics

In this chapter:

In other chapters: