View previous topic :: View next topic
|
Author |
Message |
rkprasanth_m
New User
Joined: 22 Jun 2006 Posts: 44
|
|
|
|
I have requirement to generate DSN dynamically. I want it get from a temporary data set, which has the DSN as the only line. |
|
Back to top |
|
|
Aaru
Senior Member
Joined: 03 Jul 2007 Posts: 1287 Location: Chennai, India
|
|
|
|
You can use REXX to generate DSN dynamically in a JCL.
1) Have a template JCL.
2) Copy the temporary dataset to a catalogued dataset
3) read the dataset to get the DSN name.
3) Then read the JCL and substitute the DSN value obtained from the first read thereby creating a new JCL with the DSN name
4) Submit the JCL |
|
Back to top |
|
|
rkprasanth_m
New User
Joined: 22 Jun 2006 Posts: 44
|
|
|
|
Aaru,
Thank you for your replay.
Actually, previous JCL STEP writes DSNAME to temp dataset. I want to use that DSNAME in the next Step. This DSN has Date in his name, which subject to change every time the job run.
All other way with out using REXX, using only with JCL? |
|
Back to top |
|
|
CICS Guy
Senior Member
Joined: 18 Jul 2007 Posts: 2146 Location: At my coffee table
|
|
|
|
rkprasanth_m wrote: |
Actually, previous JCL STEP writes DSNAME to temp dataset. I want to use that DSNAME in the next Step. This DSN has Date in his name, which subject to change every time the job run.
All other way with out using REXX, using only with JCL? |
Please define which executable languages and/or utilities you consider to be "JCL"...... |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
Well, you obviously need to read the temp dataset to get the name of the dataset that you need to dynamically allocate.
But why not use the job passing the DSN to allocate it for you, rather than write it out, read it in, and THEN create the dataset ??? |
|
Back to top |
|
|
rkprasanth_m
New User
Joined: 22 Jun 2006 Posts: 44
|
|
|
|
ThankYou Expat.
Well, I have a program which generates a dataset name and writes it to a temp dataset. I want to create the dataset with the name in the temp dataset.
We can't have it like that?. How could we create datasets which has dynamic names, other then writing JCL code to internal reader thru COBOL program.(DSNAME will be known at the time of execution, we can't hard code into jcl).
Could someone assist me please. |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
Then you must read the file and get the dsn and then use the dynamic allocation routines of what ever language your second program is written in. |
|
Back to top |
|
|
Devzee
Active Member
Joined: 20 Jan 2007 Posts: 684 Location: Hollywood
|
|
|
|
rkprasanth_m
If your question is to generate some kind of dynamic dataset names with date/time parameters.
Then refer to FAQ topics no longer eligible for discussion in any of these Forums:
ibmmainframes.com/viewtopic.php?t=20820 |
|
Back to top |
|
|
|