Created On:  07 November 2011

Problem:

When compiling a program with Dynamic SQL statements, customer is getting an error message:

COBSQ0325 Multiple types of SQLDA's detected - all SQLDA's must use same structure

Resolution:

The error - COBSQ0325 Multiple types of SQLDA's detected - all SQLDA's must use same structure - means:

The SQL Option preprocessor supports multiple types of SQLDA definitions. When coding them in a program, they all must be defined using the same structure or data corruption or a protection violation could occur. The preprocessor found multiple types of SQLDAs in the program. If you use a DB2 for OS/390-style SQLDA, you also need to specify the XDB directive XDB(SQLDA-VER=1) Change your SQLDA definitions to be consistent and recompile your program.

In order to use the SQLDA-VER=1 directive (in the SQL Preprocessor additional directives) you need to follow these steps:

1. From BUILD SETTING for Project/Program, open the PREPROC tab on the right hand side.

2. Click on the MORE button next to the EXEC SQL option.

3. Then enter SQLDA-VER=1 in the additional directives.

4. Recompile your program.
Incident #2538734