Hello,
Thanks for the pointer to <hlq>.CICS.SDFHPROC(DFHZITCL).
I found the file.
I have a few small problems:
1) The process was not finding the COPY books.
- I solved this by adding a new DD under the SYSLIB for COBOL
that was passed in by primary JCL with the DSName of the PDS that contains
the main cobol source, and all the COPY books for the program.
//SYSLIB DD DSN=&DSCTLIB,DISP=SHR
// DD DSN=&PROGSRC,DISP=SHR
2) I am using EXEC CICS INQUIRE commands, so the SP option was needed.
- I solved it by adding if like it is shown. Also, I deleted the SIZE option that is not needed.
This I found after a google search that discussed how someone else solved this.
This original CBLPARM
// CBLPARM=('NODYNAM,RENT', Compiler options
// 'SIZE(4000K),CICS(''COBOL3'')'), Translator options
changes to this CBLPARM
// CBLPARM=('NODYNAM,RENT', Compiler options
// 'CICS(''COBOL3,SP'')'), Translator options
3) In main JCL, I added a few parameters on EXEC statement
- PROGLIB which the procedure uses, and is the load library to store the compiled program in
- PROGSRC which is the PDS dataset that holds the cobol source and copy books
- PROGMNR which is the name of the cobol source member in PROGSRC, and should be the name of the compiled program stored in PROGLIB after LKED step
//COBOL.SYSIN DD DSN=&PROGSRC(&PROGMBR),DISP=SHR
//LKED.SYSIN DD *
NAME CMINQFDX(R)
/*
4) I was trying to change the LKED step to not use DD * and use DSN with some syntax for the member name to store, but this did not work. I might try a few more ideas, but any suggestions would be helpful.
//LKED.SYSIN DD DSN=&PROGLIB(&PROGMBR),DISP=SHR
- this does not work, and LKED step fails
//LKED.SYSIN DD *
NAME &PROGMBR(R)
- this does kind of work,
except it saved program as '&PROGMBR' in PROGLIB library
Not quite what I expected or wanted.
//LKED.SYSIN DD DSN=&PROGMBR(R)
- this is trying to create a dataset with PROGMBR name, and cannot
I was hoping to use the parameter PROGMBR for the input to LKED step, but cannot figure out a way to do it./
Thanks,
Greg
Regards,
Gregory Oakes
Professor
Faculty of Science, Engineering and Information Technology
Durham College
[cid:
image002.jpg@01D8A2A0.BD7F1900]
________________________________
This message is intended only for the named recipients. This message may contain information that is confidential or exempt from disclosure under applicable law. Any dissemination or copying of this message by anyone other than a named recipient is strictly prohibited. If you are not a named recipient or an employee or agent responsible for delivering this message to a named recipient, please notify us immediately, and permanently destroy this message and any copies you may have. Warning: Email may not be secure unless properly encrypted.
Original Message:
Sent: 5/1/2023 2:11:00 PM
From: Leigh Compton
Subject: RE: JCL sample to compile COBOL program for CICS using integrated translator
Back in the day before the integrated translator, if you had PROCEDURE DIVISION copybooks that contained EXEC CICS commands, you would need to run a translator step against the copybook and store the translated output into a different copy library which would be input to the compile job. But that procedure imposed a burden on the application developer or the DevOps team as whenever the copied code change, someone had to remember to run the translator and store the output in the 2nd copy library.
So, CICS & COBOL development gave us the integrated translator. At the time that the copy source is imported by the compiler, it is run through the CICS translator so that there's no need to maintain two versions of the copied code.
> I cannot find any good examples of how to set this up in JCL.
Fortunately, CICS delivers sample JCL procedures in SDFHPROC. <hlq>.CICS.SDFHPROC(DFHZITCL) contains the sample JCL to compile & link-edit your COBOL program.
------------------------------
Leigh Compton
Consulting IT Specialist - CICS and Enterprise Integration
IBM
TX
------------------------------
Original Message:
Sent: Mon May 01, 2023 01:39 PM
From: Gregory Oakes
Subject: JCL sample to compile COBOL program for CICS using integrated translator
Hello,
I have a cobol program to compile for CICS that has EXEC CICS statements in several of the COPY books.
I have been using the translator pre-processor followed by COBOL compiler,
but the translator does not translate the statements in the COPY books.
I considered pre-translating the COPY books, but could not work out how to do this.
Any samples or suggestions about this would be of interest.
The integrated translator looks like a great solution, but I cannot find any good examples of how to set this up in JCL. Any samples or suggestions would be great.
Regards,
Gregory Oakes
Professor
Faculty of Science, Engineering and Information Technology
Durham College
[cid:image002.jpg@01D8A2A0.BD7F1900]
________________________________
This message is intended only for the named recipients. This message may contain information that is confidential or exempt from disclosure under applicable law. Any dissemination or copying of this message by anyone other than a named recipient is strictly prohibited. If you are not a named recipient or an employee or agent responsible for delivering this message to a named recipient, please notify us immediately, and permanently destroy this message and any copies you may have. Warning: Email may not be secure unless properly encrypted.</hlq>