IGYPS0212-S SQL host variable reference "?" had invalid syntax or the referenced host variable was an invalid SQL variable type. The statement was discarded.

Explanation

This error is issued only when using the Db2® coprocessor. It is not issued when using the preprocessor.

This error occurs when using Enterprise COBOL for z/OS® V6.1, when compiling with the SQL compiler option. It affects programs that contain a Db2 SQL VARCHAR host variable where the VARCHAR structure has data items defined with level-88 condition names and the VARCHAR host variable is used in an EXEC SQL statement.

The problem is that the compiler does not accept condition names in VARCHAR host variables. If a VARCHAR host variable has level-88 condition names in its structure, then the structure is not recognized as a VARCHAR host variable.

System action

The compilation is terminated with an ABORT and RC=12.

User response

Install the PTF for APAR PI82991. The compiler is modified to recognize the VARCHAR host variable even if it has level-88 condition names in its structure.