Creating a Varray Type
varray stores an ordered set of elements in the same type.
The type can be a built-in database type or a user-defined object type.
Each element is indexed by its position in the array.
You can change elements only as a whole.
The following example creates a type named t_varray that can store up to three
SQL> CREATE TYPE t_varray AS VARRAY(3) OF VARCHAR2(50); 2 / Type created. SQL>
You can change the maximum number of elements of a varray using the
ALTER TYPE statement.
SQL> ALTER TYPE t_varray MODIFY LIMIT 10 CASCADE; Type altered. SQL>
CASCADE option propagates the change to any dependent objects in the database.