Skip to main content

This issue arose when using a federated DB2 Database connecting to a remote Oracle Database and a remote DB2 database.

When a JCL batch job was executed a COBOL program returned an SQL CODE of -30090.
Further investigation confirmed the Reason Code was 18.

The SQL statement inserts in the Remote Oracle Database and selects from the remote DB2 database.


The application is compiled with DB2ECM(Db2) and the BATCH JCL is run via IKJEKT01 and there are not commit statements in the program.

Description of SQL Code -30090 

SQL30090N Operation invalidfor application execution environment.

Reason Code 18

Do one of the following steps:

Submit a COMMIT or ROLLBACK before issuing an update to a different data source.

If multiple data sources need to be updated within a unit of work, make sure the
db2_two_phase_commit server option has been set to 'Y' for all the data sources that need to be updated.

If the data source to be updated supports only one-phase commit and the application is operating with a CONNECT type 2 connection setting, change the application to operate with a CONNECT type 1 connection setting.

Full article: https://portal.microfocus.com/s/article/KM000015725


#SupportTips/KnowledgeDocs
#EnterpriseDeveloper