Reject Files

Rows that have conversion errors during a load or rows that violate check constraints on the external table are written to a reject file. The REJECTFILE clause declares the path and file name of the reject file.

If you perform another load to the same table during the same session, any earlier reject file of the same name is overwritten.

Reject file entries have the following format:
filename, record, reason-code, 
   field-name: bad-line

The following table describes these elements of the reject file:

Element
Description
filename
Name of the input file.
record
Record number in the input file where the error was detected.
reason-code
Description of the error.
field-name
External field name where the first error in the line occurred, or <none> if the rejection is not specific to a particular column.
bad-line
Line that caused the error (delimited or fixed-position character files only).
The reject file writes the filename, record, field-name, and reason-code in ASCII. The bad-line information varies with the type of input file.
  • For delimited files or fixed-position character files, up to 80 characters of the bad line are copied directly into the reject file.
  • For HCL OneDB™ internal data files, the bad line information is not placed in the reject file because you cannot edit the binary representation in a file; but the filename, record, reason-code, and field-name are still reported in the reject file so you can isolate the problem. Use the Table Options clause to specify the format of the external data.

The following errors can cause a row to be rejected.

Error Text
Explanation
CONSTRAINT constraint name
This constraint was violated.
CONVERT_ERR
Any field encounters a conversion error.
MISSING_DELIMITER
No delimiter was found.
MISSING_RECORDEND
No end of record was found.
NOT NULL
A NULL was found in field-name.
ROW_TOO_LONG
The input record is longer than 32 kilobytes.

Virtual Processors

A FIFO virtual processor is used by external tables in HCL OneDB. One FIFO virtual processor is created when the server is initialized. Additional FIFO virtual processors can be added using the onmode -p command. For example, use the following command to add three FIFO virtual processors:
onmode -p +3 fifo
FIFO virtual processors cannot be deleted.

The FIFO virtual processors are used to process I/O related to the pipes that are defined with the PIPE clause.

See the HCL OneDB Administrator's Guide for more information about using FIFO virtual processors.