Query against an external table returns conversion error -26168

Technote (troubleshooting)


Problem(Abstract)

On a Windows system, executing a SQL select statement against an external table returns error code -26168.

The returned error message could be one of the following:

-26168: Conversion err:(file,offset,reason,col)=(<filename>,0,NO_REC_END,<none>)
-26168: Conversion err:(file,offset,reason,col)=(<filename>,0,UNSUPPORTED_ROW_SIZE,<none>)

Cause

It is possible that the external table is using a data file that was previously unloaded from a database table using DB-Access utility or the dbexport utility.

Resolving the problem

To avoid the error, define RECORDEND as '\012' in the CREATE EXTERNAL TABLE statement.

- RECORDEND: specifies the character that separates records in a delimited text file .
- \012: an ASCII value equivalent to the newline character.

Following is an example of how to create an external table with RECORDEND "\012":


CREATE EXTERNAL TABLE ext_tab1 SAMEAS tab1
USING (DATAFILES ('DISK:C:\temp\ext_tab1.unl'), RECORDEND '\012');

or:

CREATE EXTERNAL TABLE ext_tab1
(
col1 INTEGER,
col2 CHAR(15)
)
USING(DATAFILES("DISK:C:\temp\ext_tab1.unl"), RECORDEND "\012");


Where the "C:\temp\ext_tab1.unl" is an unload file previously produced by DB-Access or dbexport utility.


Related information

Defining external tables

Rate this page:

(0 users)Average rating

Document information


More support for:

Informix Servers
Informix Internet Foundation

Software version:

11.5, 11.70

Operating system(s):

Windows

Reference #:

1627845

Modified date:

2013-03-10

Translate my page

Machine Translation

Content navigation