Information on columns in base tables and views of the database.
Column name | Data type | Contents | ||||
TABLE_SCHEMA | CHAR (31) | Name of the schema to which the table | ||||
TABLE_NAME | CHAR (31) | Name of the base table or view | ||||
COLUMN_NAME | CHAR (31) | Column name | ||||
ORDINAL_POSITION | SMALLINT | Sequence number of the column in the | ||||
COLUMN_DEFAULT | VARCHAR (256) | For base tables only: Default value, as specified in the column definition TRUNCATED if representation of the default value NULL value in all other cases | ||||
IS_NULLABLE | VARCHAR (3) |
| ||||
DATA_TYPE | VARCHAR (24) | Data type of the column: | ||||
CHARACTER | SMALLINT | Max. length of the column in code units if the data type is CHARACTER, NULL value in all other cases | ||||
NUMERIC_PRECISION | SMALLINT | Total number of significant digits for numeric data types NULL value in all other cases | ||||
NUMERIC_PRECISION | SMALLINT | Radix for numeric data types NULL value in all other cases | ||||
NUMERIC_SCALE | SMALLINT | Number of digits right of the decimal point for exact numeric data types NULL value in all other cases | ||||
DATETIME_PRECISION | SMALLINT | Number of digits right of the decimal point for the data types TIME and NULL value in all other cases | ||||
The columns OLDEST_DESCRIPTOR* are assigned a value if DATA_TYPE is OLDEST: | ||||||
OLDEST_DESCRIPTOR1 | CHAR (1) | Y left-aligned N not left-aligned NULL value if DATATYPE is not OLDEST | ||||
OLDEST_DESCRIPTOR2 | CHAR (1) | Y Fill character N No fill character NULL value if DATATYPE is not OLDEST | ||||
OLDEST_DESCRIPTOR3 | CHAR (1) | Y Null (0) permitted as value N Null (0) not permitted NULL value if DATATYPE is not OLDEST | ||||
OLDEST_DESCRIPTOR4 | CHAR (1) | Y Value has arithmetic result N Value does not have arithmetic result NULL value if DATATYPE is not OLDEST | ||||
COLUMN_DESCRIPTOR1 | CHAR (1) |
| ||||
COLUMN_DESCRIPTOR2 | CHAR (1) |
| ||||
COLUMN_DESCRIPTOR3 | CHAR (1) | Y Base table column has more than one index N else | ||||
COLUMN_DESCRIPTOR4 | CHAR (1) | Y Base table column has a CALL DML default value N else | ||||
COLUMN_DESCRIPTOR5 | CHAR (1) | Y Base table column is a multiple column N else | ||||
PK_DISTANCE | SMALLINT | Distance of the column to the start of the NULL value if column is not in the primary | ||||
SESAM_SAN | CHAR (3) | Symbolic attribute name of the column NULL value if the column is not defined in | ||||
SESAM_BAN | CHAR (2) | Binary attribute name of the column NULL value if the column is not defined in | ||||
SESAM_DEFAULT | CHAR (2) | CALL DML default (with sign if numeric NULL value if the column is not defined in | ||||
FIRST_OCCURRENCE | SMALLINT | First possible occurrence of a multiple NULL value if the column is not multiple | ||||
LAST_OCCURRENCE | SMALLINT | Last possible occurrence of a multiple NULL value if the column is not multiple |
Table 111: SYS_COLUMNS view of the SYS_INFO_SCHEMA