C Data Dictionary
The Oracle Database Gateway for Teradata User's Guide translates a query that refers to an Oracle database data dictionary table into a query that retrieves the data from Teradata system catalog tables. You perform queries on data dictionary tables over the database link in the same way you query data dictionary tables in the Oracle database. The gateway data dictionary is similar to the Oracle database data dictionary in appearance and use.
Topics:
- Teradata System Catalog Tables
- Accessing the Gateway Data Dictionary
- Direct Queries to Teradata Tables
- Supported Views and Tables
- Data Dictionary Mapping
- Gateway Data Dictionary Descriptions
- ALL_CATALOG
- ALL_COL_COMMENTS
- ALL_CONS_COLUMNS
- ALL_CONSTRAINTS
- ALL_IND_COLUMNS
- ALL_INDEXES
- ALL_OBJECTS
- ALL_TAB_COLUMNS
- ALL_TAB_COMMENTS
- ALL_TABLES
- ALL_USERS
- ALL_VIEWS
- DBA_CATALOG
- DBA_COL_COMMENTS
- DBA_OBJECTS
- DBA_TAB_COLUMNS
- DBA_TAB_COMMENTS
- DBA_TABLES
- DICT_COLUMNS
- DICTIONARY
- DUAL
- USER_CATALOG
- USER_COL_COMMENTS
- USER_CONS_COLUMNS
- USER_CONSTRAINTS
- USER_IND_COLUMNS
- USER_INDEXES
- USER_OBJECTS
- USER_TAB_COLUMNS
- USER_TAB_COMMENTS
- USER_TABLES
- USER_USERS
- USER_VIEWS
C.1 Teradata System Catalog Tables
Teradata data dictionary information is stored in the Teradata database as Teradata system catalog tables. The Teradata system catalog tables define the structure of a database. When you change data definitions, Teradata reads and modifies the Teradata system catalog tables to add information about the user tables.
Parent topic: Data Dictionary
C.2 Accessing the Gateway Data Dictionary
Accessing a gateway data dictionary table or view is identical to accessing a data dictionary in an Oracle database. You issue a SQL SELECT
statement specifying a database link. The Oracle database data dictionary view and column names are used to access the gateway data dictionary in an Oracle database. Synonyms of supported views are also acceptable. For example, the following statement queries the data dictionary table ALL_CATALOG
to retrieve all table names in the Teradata database:
SQL> SELECT * FROM ALL_CATALOG@TERA;
When a data dictionary access query is issued, the gateway:
Parent topic: Data Dictionary
C.3 Direct Queries to Teradata Tables
Queries issued directly to individual Teradata system catalog tables are allowed but they return different results because the Teradata system catalog table column names differ from those of the data dictionary view. Also, certain columns in a Teradata system catalog table cannot be used in data dictionary processing.
Parent topic: Data Dictionary
C.4 Supported Views and Tables
Supported Views and Tables | Supported Views and Tables |
---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
No other Oracle database data dictionary tables or views are supported. If you use a view not on the list, you receive the Oracle database error code for no more rows available.
Queries through the gateway of any data dictionary table or view beginning with ALL_ can returns rows from the Teradata database even when access privileges for those Teradata objects have not been granted. When querying an Oracle database with the Oracle data dictionary, rows are returned only for those objects you are permitted to access.
Parent topic: Data Dictionary
C.5 Data Dictionary Mapping
The table in this section lists Oracle data dictionary view names and the equivalent Teradata system tables used. A plus sign (+) indicates that a join operation is involved.
Table C-1 Oracle Data Dictionary View Names and Teradata Equivalents
View Name | Teradata System Table Name |
---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parent topic: Data Dictionary
C.5.1 Default Column Values
There is a minor difference between the gateway data dictionary and a typical Oracle database data dictionary. The Oracle database columns that are missing in a Teradata system catalog table are filled with zeros, spaces, null values, not-applicable values (N.A.), or default values, depending on the column type.
Parent topic: Data Dictionary Mapping
C.6 Gateway Data Dictionary Descriptions
The gateway data dictionary tables and views provide the following information:
-
Name, data type, and width of each column
-
The contents of columns with fixed values
They are described here with information retrieved by an SQL*PLUS DESCRIBE
command. The values in the Null? column might differ from the Oracle database data dictionary tables and views. Any hardcoded default value is shown to the right of an item, but this is not information returned by DESCRIBE
.
Parent topic: Data Dictionary
C.7 ALL_CATALOG
Table C-2 ALL_CATALOG
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
" |
Parent topic: Data Dictionary
C.8 ALL_COL_COMMENTS
Table C-3 ALL_COL_COMMENTS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
- |
|
|
" " |
Parent topic: Data Dictionary
C.9 ALL_CONS_COLUMNS
Table C-4 ALL_CONS_COLUMNS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
- |
|
|
- |
|
|
- |
Parent topic: Data Dictionary
C.10 ALL_CONSTRAINTS
Table C-5 ALL_CONSTRAINTS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
" |
|
|
- |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
Parent topic: Data Dictionary
C.11 ALL_IND_COLUMNS
Table C-6 ALL_IND_COLUMNS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
- |
|
|
- |
|
|
- |
|
|
- |
|
|
- |
|
|
" |
Parent topic: Data Dictionary
C.12 ALL_INDEXES
Table C-7 ALL_INDEXES
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
" " |
|
|
- |
|
|
- |
|
|
" |
|
|
" |
|
|
" " |
|
|
|
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
" " |
|
|
|
|
|
|
|
|
- |
|
|
|
|
|
|
|
|
|
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parent topic: Data Dictionary
C.13 ALL_OBJECTS
Table C-8 ALL_OBJECTS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
|
|
|
|
|
|
|
|
|
" |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parent topic: Data Dictionary
C.14 ALL_TAB_COLUMNS
Table C-9 ALL_TAB_COLUMNS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
- |
|
|
- |
|
|
" " |
|
|
" " |
|
|
- |
|
|
- |
|
|
- |
|
|
" |
|
|
- |
|
|
|
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
" " |
|
|
|
|
|
" " |
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parent topic: Data Dictionary
C.15 ALL_TAB_COMMENTS
Table C-10 ALL_TAB_COMMENTS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
" |
|
|
" " |
Parent topic: Data Dictionary
C.16 ALL_TABLES
Table C-11 ALL_TABLES
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
" " |
|
|
" " |
|
|
- |
|
|
- |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
|
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
Parent topic: Data Dictionary
C.17 ALL_USERS
Table C-12 ALL_USERS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
|
|
|
|
Parent topic: Data Dictionary
C.18 ALL_VIEWS
Table C-13 ALL_VIEWS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
|
|
|
" " |
|
|
|
|
|
" " |
|
|
|
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
|
|
|
Parent topic: Data Dictionary
C.19 DBA_CATALOG
Table C-14 DBA_CATALOG
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
" |
Parent topic: Data Dictionary
C.20 DBA_COL_COMMENTS
Table C-15 DBA_COL_COMMENTS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
- |
|
|
" " |
Parent topic: Data Dictionary
C.21 DBA_OBJECTS
Table C-16 DBA_OBJECTS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
|
|
|
|
|
|
|
|
|
" |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parent topic: Data Dictionary
C.22 DBA_TAB_COLUMNS
Table C-17 DBA_TAB_COLUMNS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
- |
|
|
- |
|
|
" " |
|
|
" " |
|
|
- |
|
|
- |
|
|
- |
|
|
" |
|
|
- |
|
|
|
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
" " |
|
|
|
|
|
" " |
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parent topic: Data Dictionary
C.23 DBA_TAB_COMMENTS
Table C-18 DBA_TAB_COMMENTS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
" |
|
|
" " |
Parent topic: Data Dictionary
C.24 DBA_TABLES
Table C-19 DBA_TABLES
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
" " |
|
|
" " |
|
|
- |
|
|
- |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
|
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
Parent topic: Data Dictionary
C.25 DICT_COLUMNS
Table C-20 DICT_COLUMNS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
" " |
Parent topic: Data Dictionary
C.26 DICTIONARY
Table C-21 DICTIONARY
Name | Type | Value |
---|---|---|
|
|
- |
|
|
" " |
Parent topic: Data Dictionary
C.28 USER_CATALOG
Table C-23 USER_CATALOG
Name | Type | Value |
---|---|---|
|
|
- |
|
|
" |
Parent topic: Data Dictionary
C.29 USER_COL_COMMENTS
Table C-24 USER_COL_COMMENTS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
" " |
Parent topic: Data Dictionary
C.30 USER_CONS_COLUMNS
Table C-25 USER_CONS_COLUMNS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
- |
|
|
- |
|
|
- |
Parent topic: Data Dictionary
C.31 USER_CONSTRAINTS
Table C-26 USER_CONSTRAINTS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
" |
|
|
- |
|
|
" " |
|
|
- |
|
|
- |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parent topic: Data Dictionary
C.32 USER_IND_COLUMNS
Table C-27 USER_IND_COLUMNS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
- |
|
|
- |
|
|
- |
|
|
|
|
|
" |
Parent topic: Data Dictionary
C.33 USER_INDEXES
Table C-28 USER_INDEXES
Name | Type | Value |
---|---|---|
|
|
- |
|
|
" " |
|
|
- |
|
|
- |
|
|
" |
|
|
" |
|
|
" " |
|
|
|
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
" " |
|
|
|
|
|
|
|
|
- |
|
|
|
|
|
|
|
|
0 |
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parent topic: Data Dictionary
C.34 USER_OBJECTS
Table C-29 USER_OBJECTS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
|
|
|
|
|
|
|
|
|
" |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parent topic: Data Dictionary
C.35 USER_TAB_COLUMNS
Table C-30 USER_TAB_COLUMNS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
- |
|
|
- |
|
|
" " |
|
|
" " |
|
|
- |
|
|
- |
|
|
- |
|
|
" |
|
|
- |
|
|
|
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
" " |
|
|
|
|
|
" " |
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parent topic: Data Dictionary
C.36 USER_TAB_COMMENTS
Table C-31 USER_TAB_COMMENTS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
" |
|
|
" " |
Parent topic: Data Dictionary
C.37 USER_TABLES
Table C-32 USER_TABLES
Name | Type | Value |
---|---|---|
|
|
- |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
" " |
|
|
" " |
|
|
- |
|
|
- |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
|
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
|
|
" " |
Parent topic: Data Dictionary
C.38 USER_USERS
Table C-33 USER_USERS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
|
|
|
" |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parent topic: Data Dictionary
C.39 USER_VIEWS
Table C-34 USER_VIEWS
Name | Type | Value |
---|---|---|
|
|
- |
|
|
|
|
|
" " |
|
|
|
|
|
" " |
|
|
|
|
|
" " |
|
|
" " |
|
|
" " |
|
|
|
|
|
Parent topic: Data Dictionary