View previous topic :: View next topic
|
Author |
Message |
kavya123 Warnings : 1 New User
Joined: 11 Jul 2007 Posts: 34 Location: hyderabad
|
|
|
|
I have a requirement to pass information from REXX to JCL.
To make the requirement more clear
I have a file HLQ.FIRST and I need to create a new file HLQ.SECOND with all the units same except record length.
I want the lrec of second file to be Lrec of 1st file + some variable (20 or 50 for example).
So I am getting the record length of the 1st file from REXX and want to add it to lrec of second file
I want the creation of 2nd file only by JCL and not through REXX.
Hope the requirement is clear.
Could someone please help me out? |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
OK. I'm not clear to what your problem or question is. Your process seems to be rather straight-forward. |
|
Back to top |
|
|
Craq Giegerich
Senior Member
Joined: 19 May 2007 Posts: 1512 Location: Virginia, USA
|
|
|
|
Passing data from a step back to the job stream has been discussed many times, the only thing you can pass back to the job stream from a step is a return code. |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
Maybe I'm reading more into this topic than was intended. I'm thinking that the O/P is going to create and submit the JCL from this REXX exec to create and catalog the dataset as per the requirements. Or, in my opinion a better process, to create SORT SYSIN records for a subsequent step that copies the exisiting dataset to a new dataset with the record length modified. |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
But you could invoke ISPF to use a skeleton to create and submit a batch job |
|
Back to top |
|
|
kavya123 Warnings : 1 New User
Joined: 11 Jul 2007 Posts: 34 Location: hyderabad
|
|
|
|
superk,
I will make my problem more clear.
I want to create a flat file using a jcl.
when i submit the jcl for the first time the lrec of newly created file should be 80 say( i have hardcoded 80 in my jcl). i am using this flat file in my rexx program.
That will be fine.
the program is over.
When i used the same rexx exec next time then
i want to create the flat file again now lrec should be 80+x
where x is a value that differs each time and it will be present in the rexx exec.
i want to pass that x value in rexx ecex to jcl.
is that possible??? |
|
Back to top |
|
|
kavya123 Warnings : 1 New User
Joined: 11 Jul 2007 Posts: 34 Location: hyderabad
|
|
|
|
So,
From the above discussion can i conclude saying that
Quote: |
the only thing you can pass back to the job stream from a step is a return code. |
and we can not pass a Variable to the JCL. |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
Correct. |
|
Back to top |
|
|
kavya123 Warnings : 1 New User
Joined: 11 Jul 2007 Posts: 34 Location: hyderabad
|
|
|
|
Thank you Superk, Expert and Craq Giegerich. |
|
Back to top |
|
|
Anuj Dhawan
Superior Member
Joined: 22 Apr 2006 Posts: 6250 Location: Mumbai, India
|
|
|
|
He is "expat" not 'expert' but it's a kinda good name..
P.S.: (..just peeping into the thread..) |
|
Back to top |
|
|
UmeySan
Active Member
Joined: 22 Aug 2006 Posts: 771 Location: Germany
|
|
|
|
Hi kavya123 !
But you could store the LRECL in a variable in profile pool. So at the next use, you could read and modify the Lrecl. Then you could use FileTailoringServices for Skeleton-JCL.
Regards, UmeySan |
|
Back to top |
|
|
Paruchuri sujatha
New User
Joined: 19 Dec 2007 Posts: 7 Location: Hyderabad
|
|
|
|
Hi all,
Please help me, i have a requirement in REXX where i have to delete the datasets for region refresh. can i pass variable(contains dataset name) from rexx to a jcl, and this jcl is written in the same rexx code.
Thanks,
Ameer |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
Yes, you can use any standard acceptable JCL variable. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello Ameer,
Did you read all of the entries in this topic? If not, read them. If yes, please re-read them for better understanding. . .
You cannot directly pass information (other than return-code) from your code to "jcl".
You could use File Tailoring (mentioned above) or you could create new jcl to be submitted thru the internal reader (many examples in the forum). |
|
Back to top |
|
|
|