IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Comment multiple lines in JCL for Temporary Submits


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Wayne_in_Texas

New User


Joined: 28 Dec 2024
Posts: 10
Location: USA

PostPosted: Sun Dec 29, 2024 1:57 am
Reply with quote

Note: I've been retired a number of years now and no current access to a mainframe. I'm drawing this mostly from memory (and some saved stuff) so let me know if I've screwed something up and if this is all really common knowledge now and not really relevant, I apologize.

I rarely deleted lines when modifying JCL to do a temporary submit as it’s so easy to forget and exit out saving the member. Admittedly this goes back to when we only had ‘Edit’ and ‘Browse’ and you had to use Edit to modify lines to submit. ‘View’ has now replaced that function but I still did things the same.

Editing lines in a member can be time consuming EVEN when you want to comment them out permanently and SAVE the member. Especially a lot of JCL lines. I started using some ISPF commands to make this go faster years ago. It only requires setting up ONE PF key. I used Shift PF9 (PF21) as a quick way to comment the lines by doing a shift.

PF21 definition was
C ' ' '//*' 1 ALL X;res (note that's 3 spaces in the first set of quotes)

This PF Key has to be set up in the ISRSPEC screen (Edit or View)

In Edit (or View), put ‘))’ at the beginning of the Line command sequence of the FIRST line of a group (don't worry about the rest of the sequence numbers). Put '))3' at the beginning of the Line command sequence of the LAST line of the group (again, ignore the rest of the sequence numbers). Pressing "Enter" will slide all these lines over 3 positions to the right. Put ‘XX’ into the sequence# of the first and 'XX' into the sequence# of the last line of the group that are now blank in 1-3 and press PF21 to replace the blanks with ‘//*’. The ‘res’ at the end of the command does a reset so the screen returns clean.

Submit the job and Exit without saving. If done in View you're good to go since you can't save anyway.
Back to top
View user's profile Send private message
sergeyken

Senior Member


Joined: 29 Apr 2008
Posts: 2159
Location: USA

PostPosted: Mon Dec 30, 2024 9:53 pm
Reply with quote

It's all true, but my opinion: it is more suitable for the Beginners Forum, isn't it?

All these hints are for the first-year training on ISPF...
Back to top
View user's profile Send private message
Wayne_in_Texas

New User


Joined: 28 Dec 2024
Posts: 10
Location: USA

PostPosted: Mon Dec 30, 2024 10:23 pm
Reply with quote

Using //* to comment lines is a beginner activity, but I've found from my years of rubbing shoulders with co-coders at 6 major corporations that the tip to use a predefined PF Key along with Exclude (XX) to quickly alter blocks of JCL was an "aha" moment to many programmers well past beginner level. But that's just my opinion.

If inappropriate, I'm sure the moderators will move it.
Back to top
View user's profile Send private message
don.leahy

Active Member


Joined: 06 Jul 2010
Posts: 767
Location: Whitby, ON, Canada

PostPosted: Wed Jan 01, 2025 4:00 am
Reply with quote

I find it easier to use the XX..XX line command to exclude the lines that I don’t want to submit. Then you can use SUB NX to submit the non excluded JCL lines. Very simple and nearly idiot proof.
Back to top
View user's profile Send private message
Wayne_in_Texas

New User


Joined: 28 Dec 2024
Posts: 10
Location: USA

PostPosted: Wed Jan 01, 2025 4:58 am
Reply with quote

True, works too, but having OCD I liked to see the lines commented out on the submit. Just a visual thing to me. ¯\_(",)_/¯
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts Comment Lines getting in the way when... JCL & VSAM 0
No new posts combine multiple unique records into ... DFSORT/ICETOOL 2
No new posts System add a USER parm when job submi... TSO/ISPF 4
No new posts Mark Previous & next lines when a... DFSORT/ICETOOL 9
No new posts SORT JCL to merge multiple tow into s... DFSORT/ICETOOL 6
Search our Forums:

Back to Top