Easytrieve program calling Cobol program that is calling DB2.
Run under TSO, executing program IKJEFT01, specifying EZTPA00 for the program name or the link-edited Easytrieve program and the plan name for the COBOL Db2 program.
// EXEC PGM=IKJEFT01
//SYSTSIN DD *
DSN SYSTEM(db2ssid)
RUN PROGRAM(EZTPA00) - for compile and go, or a link-edit pgm
PLAN (cobolplan) -
LIB (loadlib)
END