Database Error Messages

Release
toggle
  • 23ai
  • 21c
  • 19c
Updated
Jun 24, 2024

SQL*Loader-00820

cannot create WHERE clause with POSITION syntax for table string

Cause

The EXTERNAL_TABLE parameter was specified for a multi-table load, and a WHEN clause for one of the tables contained a reference to a range of bytes in the record using POSITION syntax. SQL*Loader uses the WHEN clause from the control file to generate the WHERE clause in the INSERT statement. If the WHERE clause contains a reference to a range of bytes in the table, then a valid WHERE clause cannot be generated. Note that SQL*Loader will proceed as if GENERATE_ONLY was specified for the EXTERNAL_TABLE parameter.


Action

Modify the control file to only use field name references in the WHEN clause. Note that this may require creating a filler field. Another alternative is to create one control file for each table to be loaded and load the tables separately. In that case, SQL*Loader can use the access parameter list LOAD WHEN syntax to specify the range of bytes using POSITION syntax for a single table.