IBM 000-8697 User Manual

Page of 702
7-24
IBM Informix OnLine Database Server Administrator’s Guide
How to Create a Command File
The restrictions dbload imposes on the
VALUES
 clause value list affect only
data types
DATE
,
DATETIME
, and
INTERVAL
. Values of type
DATE
must be in
mm/dd/yyyy format. (This is the case if the
DBDATE
 environment variable is
set to its default value,
MDY4
/.) Data for
DATETIME
and
INTERVAL
columns
must be in character form, showing only field digits and delimiters (no type
or qualifiers).
Inserted data types correspond to the explicit or default column list. If the
data field width is different from its corresponding character column width,
the data is made to fit. That is, inserted values are padded with blanks if the
data is not wide enough for the column, or are truncated if the data is too
wide for the column.
If the number of columns named is fewer than the number of columns in the
table, dbload inserts the default value specified for the unnamed columns. If
no default is specified, dbload attempts to insert a null value. If the attempt
violates a
NOT NULL
restriction or a unique constraint, the insert fails and an
error message is returned.
If the
INSERT
statement omits the column name(s), the default
INSERT
speci-
fication is every column in the named table. If the
INSERT
statement omits the
VALUES
clause, the default
INSERT
specification is every field of the previous
FILE
 statement.
An error results if the number of column names listed (or implied by default)
does not match the number of values listed (or implied by default).
See the next section for examples of how to use the delimiter form of the
INSERT
 statement.
Delimiter Form Statement Examples
The first
FILE and INSERT
 statement set in the example on
repeated here:
FILE stock.unl DELIMITER "|" 6;
INSERT INTO stock;