"SCAN" to include instream controls & resolved datasetnames

JES, JES2, JCL utilities, IDCAMS, Compile & Run JCLs, PROCs etc...
User avatar
Steve Coalbran
Posts: 138
Joined: Wed Apr 06, 2011 11:49 am
Skillset: z/OS, JCL, TSO, REXX, ISPF, IPT, TWS
Referer: searching for associates in Google
Location: Stockholm, Sweden

"SCAN" to include instream controls & resolved datasetnames

Postby Steve Coalbran » Thu Oct 04, 2018 9:39 pm

I have a number of libraries (EQQJBLIB concatenation in IWS[OPC for us wrinklies! :D ]).
I want to "SCAN" these JCL JOBs which include input controls (for a particular program we are reviewing) both as [DD *] instream controls as well as [DD DSN=] references.
I want to logically SCAN the JCL JOBs and the result should include both: any instream controls as well as all resolved datasetname references.
I have tried 2 approaches:
  • Just read theJCL and look for instream controls. Yes nowadays they could be in an included PROC but nobody uses this "new" feature.
    This misses any datasets with symbolic variables (most!)
  • Resolve the JCL stream:
    • SCAN the JOB
    • Trap the output in SDSF
    • Analyse the resolved datasetname references
    This misses any instream controls.
Does anyone know how I could achieve all this in one go? :)
Steve

enrico-sorichetti
Global moderator
Posts: 3006
Joined: Fri Apr 18, 2008 11:25 pm
Skillset: tso,rexx,assembler,pl/i,storage,mvs,os/390,z/os,
Referer: www.ibmmainframes.com

Re: "SCAN" to include instream controls & resolved datasetna

Postby enrico-sorichetti » Thu Oct 04, 2018 10:01 pm

when using sdsf interactive the command "input on" lets You see all the "DD *" stuff
if You plan to use the REXX/SDSF interface, check the manual to see if the construct is supported
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort

User avatar
Steve Coalbran
Posts: 138
Joined: Wed Apr 06, 2011 11:49 am
Skillset: z/OS, JCL, TSO, REXX, ISPF, IPT, TWS
Referer: searching for associates in Google
Location: Stockholm, Sweden

Re: "SCAN" to include instream controls & resolved datasetna

Postby Steve Coalbran » Thu Oct 11, 2018 3:24 pm

Will try and locate the correct manual for this.
I find the REXX interface particularly difficult to use compared to other APIs. ;)
Anyone out there happen to have a handy example of how one might do this from REXX? (if as you suggest Enrico, it is indeed available here?) :D
Steve

enrico-sorichetti
Global moderator
Posts: 3006
Joined: Fri Apr 18, 2008 11:25 pm
Skillset: tso,rexx,assembler,pl/i,storage,mvs,os/390,z/os,
Referer: www.ibmmainframes.com

Re: "SCAN" to include instream controls & resolved datasetna

Postby enrico-sorichetti » Thu Oct 11, 2018 4:19 pm

I posted quite a few WORKING examples of the rexx sdsf interface

in this forum and on the sibling one http://ibmmainframes.com

search my posts with "sdsf rexx"

beware that when run in batch the authorization logic has to be implemented using RACF
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort

enrico-sorichetti
Global moderator
Posts: 3006
Joined: Fri Apr 18, 2008 11:25 pm
Skillset: tso,rexx,assembler,pl/i,storage,mvs,os/390,z/os,
Referer: www.ibmmainframes.com

Re: "SCAN" to include instream controls & resolved datasetna

Postby enrico-sorichetti » Fri Oct 12, 2018 1:18 pm

cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort

User avatar
Steve Coalbran
Posts: 138
Joined: Wed Apr 06, 2011 11:49 am
Skillset: z/OS, JCL, TSO, REXX, ISPF, IPT, TWS
Referer: searching for associates in Google
Location: Stockholm, Sweden

Re: "SCAN" to include instream controls & resolved datasetna

Postby Steve Coalbran » Fri Oct 12, 2018 2:06 pm

It gives an RC(8) but it does actually work from REXX...

Code: Select all

195 *-*    RC = ISFCALLS("ON")                  
    >>>      "0"                                
196 *-*    isffilter = 'JOBID EQ 'jobid          
    >>>      "JOBID EQ JOB70763"                
197 *-*    ADDRESS SDSF "ISFEXEC ST "            
    >>>      "ISFEXEC ST "                      
198 *-*    ADDRESS SDSF "ISFEXEC PREFIX" jobname
    >>>      "ISFEXEC PREFIX TESTSDSF"          
    +++ RC(8) +++                                
199 *-*    ADDRESS SDSF "ISFEXEC INPUT ON "      
    >>>      "ISFEXEC INPUT ON "                
    +++ RC(8) +++                                
:D
Steve

willy jensen
Posts: 474
Joined: Thu Mar 10, 2016 5:03 pm
Skillset: assembler rexx zOS ispf racf smf
Referer: saw it in the experts foprum thought I could help here

Re: "SCAN" to include instream controls & resolved datasetna

Postby willy jensen » Sat Oct 13, 2018 6:13 pm

Instead of 'ISFEXEC PREFIX' try setting variable ISFPREFIX to your prefix value. Likewise, use variables isfowner, isfsysname and isfdest. Refer to the 'SDSF User's Guide' manual for details.

enrico-sorichetti
Global moderator
Posts: 3006
Joined: Fri Apr 18, 2008 11:25 pm
Skillset: tso,rexx,assembler,pl/i,storage,mvs,os/390,z/os,
Referer: www.ibmmainframes.com

Re: "SCAN" to include instream controls & resolved datasetna

Postby enrico-sorichetti » Sat Oct 13, 2018 7:34 pm

ISFPREFIX to your prefix value
.

thats what I used in the snippets in the link i posted
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort


  • Similar Topics
    Replies
    Views
    Last post