Informix Error -809: SQL Syntax error has occurred.
Cause and resolution
SQL Syntax error has occurred.
The INSERT statement in this LOAD/UNLOAD/INFO statement has invalid syntax. Review it for punctuation and use of keywords.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-809 fires when a LOAD/UNLOAD/INFO statement's embedded INSERT statement has invalid
syntax — per the official guidance, this is specific to the generated/specified INSERT used by
these statements, not a general SQL syntax error.
- A malformed
INSERTclause within aLOADstatement, per the official guidance — a punctuation or keyword error in that specific clause. - A hand-written
INSERTclause forLOAD/UNLOAD/INFOthat doesn't follow the exact syntax these statements expect, even if it would be valid as a standaloneINSERT.
Solutions / Resolution
- Review the
INSERTstatement for punctuation and correct use of keywords, per the official guidance. - Compare the
INSERTclause's syntax against the documentedLOAD/UNLOAD/INFOstatement syntax, since these contexts have their own specific requirements distinct from a standaloneINSERT.
Examples
A malformed INSERT clause within LOAD
LOAD FROM 'orders_import.unl' INSERT INTO orders VALUES;
-- -809: incomplete INSERT syntax (missing the values/column list)
Corrected
LOAD FROM 'orders_import.unl' INSERT INTO orders;
Diagnostic Checks
- Review the exact
INSERTclause text for punctuation and keyword correctness, against the specificLOAD/UNLOAD/INFOstatement syntax documented for the server version in use.
Related Errors / Related Topics
No closely related error codes are cross-referenced for -809 in this set yet.
Specific to the INSERT clause within LOAD/UNLOAD/INFO — check its syntax against those
statements' specific documented form.