Column Validation File (.val)
The .val database schema file holds functional and display attributes of database table columns.
Description
The .val file holds default attributes and validation rules for database columns.
In form files, the attributes are taken from the .val file as defaults if
the corresponding attribute is not explicitly specified in the field definition of the
ATTRIBUTES
section. The attributes in the .val file can be
considered as a default configuration for a form field.
In
programs, you can validate variable values in accordance with the INCLUDE
attribute
by using the VALIDATE
instruction.
The .val file can be generated by fgldbsch from the IBM®
Informix® specific syscolval
table, or
can be edited by an external column attributes editor.
This table describes the structure of the .val file:
Pos | Type | Description |
---|---|---|
|
STRING | Database table name. |
|
STRING | Column name. |
|
STRING | Column property name. |
|
STRING | Column property value. |
The supported attribute definitions are:
Attribute Name | Description |
---|---|
|
Defines the When
this attribute is defined, value is |
|
Defines the The
value must be one of: |
|
Defines the The value is a color identifier (RED, GREEN, BLUE, ...) |
|
Defines the The
value is a quoted string or Localized String ( |
|
Defines the Number,
quoted string or identifier ( |
|
Defines the The value is a quoted string. |
|
Defines an include list as the Value
must be a list: |
|
Defines the When
this attribute is defined, value is |
|
Defines the The
value must be one of: |
|
Defines the The value is a quoted string. |
|
Corresponds to the Values
can be |
|
Defines the When
this attribute is defined, value is |
Example
customer^customer_name^SHIFT^UP^
customer^customer_name^COMMENTS^"Name of the customer"^
order^order_date^DEFAULT^TODAY^
order^order_date^COMMENTS^"Creation date of the order"^