Problem:
It seems that a PREPARE statement is not running correctly within an OpenESQL application using dynamic SQL.
You may also find the SQL Descriptor Area (SQLDA) structure is not set as expected.
Resolution:
You should check your application regarding the SQLDA items SQLN and SQLDABC first because it is a must to initialise these items before you can run PREPARE.
SQLN This must be set to the maximum number of SQLVAR entries that the structure can hold.
SQLDABC The maximum size of the SQLDA. This is calculated as SQLN * 44 16