Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Passing parameters to a jcl submitted through REXX.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> All Other Mainframe Topics
View previous topic :: :: View next topic  
Author Message
Roshnii

New User


Joined: 30 Sep 2008
Posts: 45
Location: bangalore

PostPosted: Tue Apr 28, 2009 6:01 pm    Post subject: Passing parameters to a jcl submitted through REXX.
Reply with quote

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
View user's profile Send private message

superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Tue Apr 28, 2009 6:03 pm    Post subject: Reply to: Passing parameters to a jcl submitted through REXX
Reply with quote

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
View user's profile Send private message
Roshnii

New User


Joined: 30 Sep 2008
Posts: 45
Location: bangalore

PostPosted: Tue Apr 28, 2009 6:30 pm    Post subject:
Reply with quote

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
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Tue Apr 28, 2009 6:33 pm    Post subject:
Reply with quote

Please explain exactly what you require and maybe we can help you better
Back to top
View user's profile Send private message
Roshnii

New User


Joined: 30 Sep 2008
Posts: 45
Location: bangalore

PostPosted: Tue Apr 28, 2009 6:43 pm    Post subject:
Reply with quote

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
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Tue Apr 28, 2009 7:06 pm    Post subject: Reply to: Passing parameters to a jcl submitted through REXX
Reply with quote

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
View user's profile Send private message
Roshnii

New User


Joined: 30 Sep 2008
Posts: 45
Location: bangalore

PostPosted: Wed Apr 29, 2009 5:51 pm    Post subject: Reply to: Passing parameters to a jcl submitted through REXX
Reply with quote

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
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Wed Apr 29, 2009 6:52 pm    Post subject: Reply to: Passing parameters to a jcl submitted through REXX
Reply with quote

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
View user's profile Send private message
Douglas Wilder

Active User


Joined: 28 Nov 2006
Posts: 305
Location: Deerfield IL

PostPosted: Wed Apr 29, 2009 8:08 pm    Post subject:
Reply with quote

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
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> All Other Mainframe Topics All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
This topic is locked: you cannot edit posts or make replies. Calling REXX code from ISPF panel sanchita dey TSO/ISPF 4 Mon Jan 02, 2017 5:13 pm
No new posts REXX DB2: Dynamic allocation of DB2.D... BHAS CLIST & REXX 3 Mon Dec 19, 2016 8:26 pm
No new posts find particular member name in PDS us... ravi243 CLIST & REXX 10 Mon Dec 19, 2016 6:44 pm
This topic is locked: you cannot edit posts or make replies. Get a job submitted itself every time... arunsoods JCL & VSAM 3 Tue Nov 22, 2016 4:05 pm
No new posts What is the command to check MODE of ... rohanthengal CLIST & REXX 7 Fri Nov 18, 2016 1:48 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us