You must have the Micro Focus Rumba product installed and have it configured to connect to your mainframe.
//MFIXCH02 JOB (DB2JOB),'DB2 JOB',REGION=4M, // CLASS=A,MSGCLASS=X,MSGLEVEL=(1,1) //UNLOAD1 EXEC PGM=DSNUTILB,REGION=0M,PARM='DB9R,MFIXCH' //STEPLIB DD DSN=DSN910.SDSNLOAD,DISP=SHR //SYSREC DD DSN=MFIXCH.UTILBTS.SYSREC1, // DISP=(MOD,CATLG), // UNIT=SYSDA,SPACE=(CYL,(1,1)) //SYSPUNCH DD DSN=MFIXCH.UTILBTS.PUNCH1, // UNIT=SYSDA,SPACE=(TRK,(1,1)),DISP=(MOD,CATLG) //SYSPRINT DD SYSOUT=* //UTPRINT DD DUMMY //SORTOUT DD UNIT=SYSDA,SPACE=(4000,(20,20),,,ROUND) //SYSDISC DD DUMMY //SYSERR DD UNIT=SYSDA,SPACE=(4000,(20,20),,,ROUND) //SYSMAP DD UNIT=SYSDA,SPACE=(4000,(20,20),,,ROUND) //SYSUT1 DD UNIT=SYSDA,SPACE=(4000,(20,20),,,ROUND) //SYSIN DD * NLOAD DATA FROM TABLE DSN8910.EMP /* //
MFDAS IMPORT datFilePath\DSN8910_EMP.DAT FROM AUTO mainframeID.UTILBTS.SYSREC1 /CATLOC=ESWorkArea\DSNUTILS\catalog.dat
//JCLTEP2 JOB //RESETDB EXEC PGM=IKJEFT01 //SYSTSPRT DD SYSOUT=* //SYSPRINT DD SYSOUT=* //SYSPUNCH DD SYSOUT=* //SYSREC00 DD SYSOUT=* //SYSUDUMP DD SYSOUT=* //SYSOUT DD SYSOUT=* //SYSTSIN DD * DSN SYSTEM(HCOD) RUN PROGRAM(HCOTEP2) END /* //SYSIN DD * CREATE TABLE DSN8910.EMP ( EMPNO CHAR(6) NOT NULL, FIRSTNME VARCHAR(12) NOT NULL, MIDINIT CHAR(1) NOT NULL, LASTNAME VARCHAR(15) NOT NULL, WORKDEPT CHAR(3), PHONENO CHAR(4), HIREDATE DATE, JOB CHAR(8), EDLEVEL SMALLINT, SEX CHAR(1), BIRTHDATE DATE, SALARY DECIMAL(9,2), BONUS DECIMAL(9,2), COMM DECIMAL(9,2), PRIMARY KEY (EMPNO) ) IN DATABASE DBNATS; /* //
//JCLUTILB JOB //DSNUPROC EXEC PGM=HCOUTILB,PARM='HCOD,SH ' //* //SYSPRINT DD SYSOUT=* //UTPRINT DD SYSOUT=* //SYSUDUMP DD SYSOUT=* //STPRIN01 DD SYSOUT=* //IDIOFF DD DUMMY //* //SYSUT1 DD DISP=MOD,DSN=SH.DSNUTILB.SYSUT1 //SORTOUT DD DISP=MOD,DSN=SH.DSNUTILB.SYSOUT //SYSMAP DD DISP=MOD,DSN=SH.DSNUTILB.SYSMAP //SYSERR DD DISP=MOD,DSN=SH.DSNUTILB.SYSERR //SYSREC DD DISP=SHR,DSN=MFIXCH.UTILBTS.SYSREC1 //SYSIN DD * LOAD DATA INDDN SYSREC LOG NO RESUME NO REPLACE EBCDIC CCSID(00037,00000,00000) INTO TABLE "DSN8910". "EMP" WHEN(00001:00002) = X'0012' NUMRECS 42 ( "EMPNO" POSITION( 00003:00008) CHAR(00006) , "FIRSTNME" POSITION( 00009:00022) VARCHAR , "MIDINIT" POSITION( 00023:00023) CHAR(00001) , "LASTNAME" POSITION( 00024:00040) VARCHAR , "WORKDEPT" POSITION( 00042:00044) CHAR(00003) NULLIF(00041)=X'FF' , "PHONENO" POSITION( 00046:00049) CHAR(00004) NULLIF(00045)=X'FF' , "HIREDATE" POSITION( 00051:00060) DATE EXTERNAL NULLIF(00050)=X'FF' , "JOB" POSITION( 00062:00069) CHAR(00008) NULLIF(00061)=X'FF' , "EDLEVEL" POSITION( 00071:00072) SMALLINT NULLIF(00070)=X'FF' , "SEX" POSITION( 00074:00074) CHAR(00001) NULLIF(00073)=X'FF' , "BIRTHDATE" POSITION( 00076:00085) DATE EXTERNAL NULLIF(00075)=X'FF' , "SALARY" POSITION( 00087:00091) DECIMAL NULLIF(00086)=X'FF' , "BONUS" POSITION( 00093:00097) DECIMAL NULLIF(00092)=X'FF' , "COMM" POSITION( 00099:00103) DECIMAL NULLIF(00098)=X'FF' ) /* //
//JCLINDX JOB //RESETDB EXEC PGM=IKJEFT01 //SYSTSPRT DD SYSOUT=* //SYSPRINT DD SYSOUT=* //SYSPUNCH DD SYSOUT=* //SYSREC00 DD SYSOUT=* //SYSUDUMP DD SYSOUT=* //SYSOUT DD SYSOUT=* //SYSTSIN DD * DSN SYSTEM(HCOD) RUN PROGRAM(HCOTEP2) END /* //SYSIN DD * ALTER TABLE DSN8910.EMP ADD CONSTRAINT MIN_SALARY CHECK (SALARY > 15000.00); CREATE INDEX DSN8910.XEMP2 ON DSN8910.EMP(WORKDEPT); /* //