Oracle® Database PL/SQL Language Reference 11g Release 2 (11.2) Part Number E10472-02 |
|
|
View PDF |
The %ROWTYPE
attribute lets you declare a record that represents a row of a database table or view: For every column of the row, the record has a field with the same name and data type.
The record fields do not inherit the constraints or initial values of the corresponding columns.
If the structure of the row changes, the structure of the record changes accordingly.
Topics:
Syntax
%rowtype_attribute ::=
Semantics
cursor_name
The name of an explicit cursor.
cursor_variable_name
The name of a strongly typed cursor variable.
table_name
The name of a database table or view that is accessible when the declaration is elaborated.
Examples
Example 2-16, "Declaring a Record that Represents a Subset of Table Columns"
Example 2-17, "Declaring a Record that Represents a Row from a Join"
Example 5-7, "Specifying Collection Element Types with %TYPE and %ROWTYPE"
Example 5-20, "Assigning Values to VARRAYs with Complex Data Types"
Example 6-25, "Cursor Variables Returning %ROWTYPE Variables"
Related Topics
In this chapter:
In other chapters: