Page 1 of 1

How to pass values to sysin(jcl) through REXX.

PostPosted: Fri May 18, 2012 7:43 pm
by Viswanathchandru
Dear all,

Again, here i'm to learn/get knowledge, hope i would get! Can anyone tell me how can we pass values to the sysin control card through rexx. Any links or libraries would help. Please advice.

Regards,
Viswa

Re: How to pass values to sysin(jcl) through REXX.

PostPosted: Fri May 18, 2012 8:23 pm
by steve-myers
This topic was discussed in this section of the forum last month. Read that topic first!

Re: How to pass values to sysin(jcl) through REXX.

PostPosted: Fri May 18, 2012 8:33 pm
by Viswanathchandru
Thanks steve for your time! yes as advised i went through the forum. I'm able to find passing DD names but i can't find how to pass values to sysin control card. Please advice. Apologize if i or my thoughts are wrong!

Regards,
Viswa

Re: How to pass values to sysin(jcl) through REXX.

PostPosted: Fri May 18, 2012 8:46 pm
by mongan
Simply, you can not do it. You have to generate the sysin cards with the values resolved from your rexx and then use them. You will have to take a little more time and search for the many answers and solutions already posted here.

Re: How to pass values to sysin(jcl) through REXX.

PostPosted: Fri May 18, 2012 9:35 pm
by Pedro
pass values to the sysin control card through rexx


You need to provide more details. Where is the rexx running? What does your JCL look like.

It could be as simple as two job steps... the first is a rexx program that builds the SYSIN using a:
//FILE1    DD  DISP=(NEW,PASS),DSN=&&TMP

The second step would refer to the file with
//SYSIN   DD DISP=(OLD,DELETE),DSN=&&TMP

Re: How to pass values to sysin(jcl) through REXX.

PostPosted: Fri May 18, 2012 9:47 pm
by Viswanathchandru
Hello Pedro,

Thanks for your time! sorry for not being clear! The REXX routine just gets a value either through panel/ or just through a pull and that variable has to be under the sysin control card. REXX runs under the ISPEXEC environment. I believe this could work. But how do write a single value into a Dataset. Confused. Will this work.? Just a wild guess. Apologize if its wrong!

Do i=1 to 2
pull list.i
"alloc dd(indd) da('"mxg.control.input"') shr reuse
"execio * diskw indd(finis"
end


Regards,
Viswa

Re: How to pass values to sysin(jcl) through REXX.

PostPosted: Fri May 18, 2012 9:48 pm
by NicC
Why do you not try it out?

Re: How to pass values to sysin(jcl) through REXX.

PostPosted: Sat May 19, 2012 2:43 am
by Pedro
The real title of this thread should be 'How do I write to a dataset?'

When you mention 'passing values', 'JCL', and 'sysin', it clouds the issue and you get 'cannot be done' responses.