How to pass a parameter to the in stream program



JES, JES2, JCL utilities, IDCAMS, Compile & Run JCLs, PROCs etc...

How to pass a parameter to the in stream program

Postby GeorgeQ » Wed Jan 24, 2018 4:49 am

Hello everyone,
The code below is from this link:
https://www.ibm.com/support/knowledgece ... tsorun.htm
May I ask if it is possible that I can use "//SET1 SET DSN1=NAME1"
so I can use &DSN1 inside the in stream code to deliver value "NAME1".


//TSOBATCH EXEC PGM=IKJEFT01,DYNAMNBR=30,REGION=4096K
//SYSEXEC DD DSN=USERID.MYREXX.EXEC,DISP=SHR
//SYSTSPRT DD SYSOUT=A
//SYSTSIN DD *
%TEST4
&DSN1
/*
//
GeorgeQ
 
Posts: 28
Joined: Fri Jun 16, 2017 1:08 am
Has thanked: 12 times
Been thanked: 0 time

Re: How to pass a parameter to the in stream program

Postby Robert Sample » Wed Jan 24, 2018 4:58 am

This is one of those cases where you MUST contact your site support group for assistance -- since we on this forum do not work at your site, we cannot provide you a definitive answer. JCL symbols may be used in in-stream data sets when:
- z/OS 2.1 (or higher) is being used
- the site support group has added in-stream symbol support into JES
- in-stream symbol support is by job class, so even if the above are both true, if you use a job class for which in-stream symbol support has not been defined then you cannot use symbols in your job and only your site support group can tell you which job classes allow in-stream symbols

These users thanked the author Robert Sample for the post:
GeorgeQ (Wed Jan 24, 2018 5:08 am)
Robert Sample
Global moderator
 
Posts: 3719
Joined: Sat Dec 19, 2009 8:32 pm
Location: Dubuque, Iowa, USA
Has thanked: 1 time
Been thanked: 279 times

Re: How to pass a parameter to the in stream program

Postby GeorgeQ » Wed Jan 24, 2018 5:20 am

Thank you very much Robert!

I will contact them after I do some research on how to use and write REXX program.

Let me briefly descript the original problem I meet here:
This JCL job will call a REXX program let's name it TEST4.
The TEST4 will ftp transfer some file from mainframe to UNIX server. the whole process don't have any problem so far. but for myself I want to add some extra feature to it, I want to use symbol dynamically rename the file ftp to UNIX. let me name this new file "newfile&DSN1..txt"
GeorgeQ
 
Posts: 28
Joined: Fri Jun 16, 2017 1:08 am
Has thanked: 12 times
Been thanked: 0 time


Return to JCL

 


  • Related topics
    Replies
    Views
    Last post