View previous topic :: View next topic
|
Author |
Message |
Roshnii
New User
Joined: 30 Sep 2008 Posts: 45 Location: bangalore
|
|
|
|
I am submitting a job using REXX.
I am using this command
Code: |
ADDRESS TSO "SUBMIT <dsn name (member)'"
|
I want to know how do I pass the parameters to the JCl?
Any help? |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
You don't. JCL doesn't take parameters.
And, for the sake of accuracy, you're not submitting a job using REXX. You're submitting a job using TSO. |
|
Back to top |
|
|
Roshnii
New User
Joined: 30 Sep 2008 Posts: 45 Location: bangalore
|
|
|
|
Thanks.
So is there any way that I can pass file names to the jcl that i will submitting through TSO? using any other command for submitting the job?
Thanks,
Roshnii |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
Please explain exactly what you require and maybe we can help you better |
|
Back to top |
|
|
Roshnii
New User
Joined: 30 Sep 2008 Posts: 45 Location: bangalore
|
|
|
|
I need to submit a job to copy the protsym from one region to another region.
I have the job ready and it works. But depending on the regions where I need to move and to which region I need to move, the Dsname changes.
So I wanted to know, if it is possible to pass the dsnames to the jcl before submitting it.
And I have to use rexx for the entire operation.
I hope its not confusing. |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
I'm moving this out of the REXX forum since your problem and potential solution isn't really REXX-related.
I see some options you may want to consider:
- you can edit the JCL, make the changes to the datasets as needed, then save it and submit it.
- you can read the JCL into a REXX stem variable. Then, make the changes to the dataset names as needed. Push the stem variables into the stack, and use the TSO SUBMIT command to submit the JCL from the data stack rather than from a dataset.
- you can use ISPF File Tailoring services to generate and submit the appropriate JCL.
- you can use JCL SET, INCLUDE, and/or Procedures to specify the dataset names as needed. |
|
Back to top |
|
|
Roshnii
New User
Joined: 30 Sep 2008 Posts: 45 Location: bangalore
|
|
|
|
thanks for the soultions.
I am trying this approach.
- copied the jcl to a flat file.
- use 'change all' command to replace the member and pds
- submit the jcl
But how do I issue the change all command for the flat file inside the rexx program? |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
Presuming you're running the REXX exec from within TSO, then you can use TSO commands from within the exec the same way you do natively.
In your case, I just tried this code as a test:
Code: |
/* REXX */
...
Queue "TOP"
Queue "C * 999999 /OLD/NEW/"
Queue "END SAVE"
"EDIT YOURDSN CNTL NONUM OLD"
...
|
and it worked just fine. |
|
Back to top |
|
|
Douglas Wilder
Active User
Joined: 28 Nov 2006 Posts: 305 Location: Deerfield IL
|
|
|
|
If you need to change all occurrences add ALL to the CHANGE sub command of EDIT.
Code: |
Queue "C * 999999 /OLD/NEW/ ALL" |
|
|
Back to top |
|
|
|