Note
This view is available starting with V2.2.30.
Purpose
This view lists the user-defined collection types owned by the current user.
Applicability
This view applies only to OceanBase Database in Oracle mode.
Columns
| Column | Type | Null | Description |
|---|---|---|---|
| TYPE_NAME | VARCHAR2(64) | NO | The name of the type. |
| COLL_TYPE | VARCHAR2(10) | NO | The collection type: |
| UPPER_BOUND | NUMBER(38) | YES | The maximum size of the collection for the VARYING type. |
| ELEM_TYPE_MOD | VARCHAR2(7) | YES | This column is not supported. The default value is NULL. |
| ELEM_TYPE_OWNER | VARCHAR2(128) | YES | The owner of the type of the collection element. |
| ELEM_TYPE_NAME | VARCHAR2(324) | YES | The name of the type of the collection element. |
| LENGTH | NUMBER(38) | YES | The length of the type of the collection element. |
| NUMBER_PRECISION | NUMBER(38) | YES | The precision of the type of the collection element. |
| SCALE | NUMBER(38) | YES | The length of the data to the right of the decimal point of the type of the collection element. |
| CHARACTER_SET_NAME | CHAR(7) | YES | The character set of the type of the collection element. |
| ELEM_STORAGE | CHAR(7) | YES | This column is not supported. The default value is NULL. |
| NULLS_STORED | CHAR(7) | YES | This column is not supported. The default value is NULL. |
Sample query
Query the user-defined collection types owned by the current user.
obclient [SYS]> SELECT * FROM SYS.USER_COLL_TYPES;
The query result is as follows:
+--------------+-----------+-------------+---------------+-----------------+----------------+--------+------------------+-------+--------------------+--------------+--------------+
| TYPE_NAME | COLL_TYPE | UPPER_BOUND | ELEM_TYPE_MOD | ELEM_TYPE_OWNER | ELEM_TYPE_NAME | LENGTH | NUMBER_PRECISION | SCALE | CHARACTER_SET_NAME | ELEM_STORAGE | NULLS_STORED |
+--------------+-----------+-------------+---------------+-----------------+----------------+--------+------------------+-------+--------------------+--------------+--------------+
| PROJECT_LIST | TABLE | -1 | NULL | NULL | VARCHAR2 | 100 | 2 | -1 | CHAR_CS | YES | B |
+--------------+-----------+-------------+---------------+-----------------+----------------+--------+------------------+-------+--------------------+--------------+--------------+
1 row in set
References
To view all custom collection types in the current tenant, see DBA_COLL_TYPES.
To view all custom collection types accessible to the current user, see ALL_COLL_TYPES.
For more information about collections, see Collections.