Let’s begin solving part three its challenges.
But first, I’ll give you a heads-up on what I’m going to do. Last year I wasn’t allowed to release the answers to part three. I asked the new manager (Misty Decker) about any rules regarding blogs but I have yet to get a reply. So, I’ll just give clear instructions on the easy challenges and no answers to the harder challenges. If there’s anything IBM wishes me to censor then please contact me using an official IBM mail address or via Slack.
IBM Master the Mainframe Part Three – Challenge #01
How to get started
For starters we’ll issue the primary command tso sub ‘zos.public.jcl(part3)’ from the ISPF Primary Option menu to allocate the part 3 data sets.
I have submitted the command and chose the jobname character ‘a’.
Exposure to REXX, the z/OS all purpose scripting language
REXX is cool. Seriously. Our first assignment is to edit Z#####.REXX and create a new member hello using the primary command s. After that we’ll copy ‘zos.mtm2019.public.rexx(hello)’ into our new member.
Now I have this.
I have copied it. The script displays basic capabilities of string concatenation at line 16 (in comment), basic usage of arrays from line 9 to line 11, disk read and write and finally some say commands to display information to the screen.
Execute modified REXX
First we need to modify the REXX script.
- Change lines 9, 10, and 11 to be comments
- Change lines 13, 14, 15, and 16 to execute – remove comment markers
Now all that’s left to do is execute this script. We can do so by going back to the dslist and entering line command ex from execute next to the member name hello.
I pressed enter and in the lower part of my screen it said hello. The script works!
Normally this output should now be in P3.OUTPUT(#01). Let’s check to see if we completed challenge 01 of part 3.
AHA! I have it! We have completed the challenge!