DB2 Program Execution Process

DB2 Isolation Levels DB2 Host Variables

Advertisements


To execute COBOL + DB2 program, the program should BIND successfully first.

The execution process is depending on the executing environment.

Batch environment:

After successful BIND, the program will need a JCL to RUN.

IKJEFT01 utility is used to execute the program through JCL.

The below one is the RUN JCL for COBOL+DB2 program:

	//JOB CARD
	//S-1 EXEC PGM=IKJEFT01
	//SYSIN DD *
		RUN PROG (P1) PLAN (Pl1)
		DSN SYSTEM (DSP/DST)
		LIB (Z.Z.A)
	/*
	//

In the above,

	P1			- 	Program name which needs to execute.
	Pl1			-	Plan name to which the program BIND.
	DSP/DST			-	DB2 system name
	Z.Z.A			-	Library name

Online Environment:

After successful BIND, program new copy to be issued in CICS environment.

Before running the module, the RCT entry for the program should be defined in the region. Otherwise, query execution will fail with -922 error.

Once the new copy successfully issued, LINKing/CALLing the program from other program is sufficient to run the COBOL + DB2 program.

If the COBOL + DB2 module has a transaction associated with it, triggering transaction also initiates the execution.


DB2 Isolation Levels DB2 Host Variables

Advertisements