View previous topic :: View next topic
|
Author |
Message |
shivkumar
New User
Joined: 06 Mar 2009 Posts: 8 Location: Pune
|
|
|
|
Hi,
My requirement is to write symbolic parameter in sortout file. As
Code: |
//STEP030 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=ZRP..C&YR.&MTH..C&CYCL.T&CTN..SV&PRCID,
// DISP=SHR
//SORTOUT DD DSN=ZRP..C&YR.&MTH..C&CYCL.T&CTN..SV&PRCID..SRTD1,
// DISP=(,CATLG,DELETE),
// SPACE=(CYL,(50,50),RLSE)
//SYSIN DD * |
????????
Here &YR = 10, &MTH = 06, &CYCL = 01 and & CTN = 01
means I want in output file. These parameter are not fixed (these are coming from another job).
10 06 01 01 --------(other data) |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
You must use a program of your own design that accepts those symbolic variables through a PARM= statement and writes them out to a dataset in whatever manner you need. |
|
Back to top |
|
|
shivkumar
New User
Joined: 06 Mar 2009 Posts: 8 Location: Pune
|
|
|
|
My requirement is thru JCL.
Especially thru SORT |
|
Back to top |
|
|
Garry Carroll
Senior Member
Joined: 08 May 2006 Posts: 1193 Location: Dublin, Ireland
|
|
|
|
Your requirement is unclear.
Do you want the symbolics stored as contents of the file or do you want to use the symbolics in the name of the file - or both?
You don't specify the DCB information for either file or give any clue as to content.
Garry. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
How are these parameters getting into "this" job from the other job?
You have a scrap of jcl that references some symbolics, but there is no info as to how these are presented to this run? Is this one step in a PROCedure? Something else? |
|
Back to top |
|
|
shivkumar
New User
Joined: 06 Mar 2009 Posts: 8 Location: Pune
|
|
|
|
Garry & Dick,
I want symbolic content to be in file. All these symbolic parameter will come from different job. So I don't have control on these.
This is a job; which will send symbolic parameter & triggered by another job. e.g.
JOB1 will take up &YR , &MTH, &CYCL and &CTN values and passes to JOB2. And JOB2 will have write step (pls check my first post).
My requirement is to column wise Print these Symbolic parameter into output file and other data. |
|
Back to top |
|
|
Garry Carroll
Senior Member
Joined: 08 May 2006 Posts: 1193 Location: Dublin, Ireland
|
|
|
|
I'm still confused. What are you trying to achieve?
Quote: |
JOB1 will take up &YR , &MTH, &CYCL and &CTN values and passes to JOB2. |
I don't understand this. How can a job send a symbolic parameter to another job?
How would you propose that a step in a submitted job would access its own JCL in order to see the parameters used?
Garry. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
It is not yet clear what you want/need. I believe you know what you are looking for, but so far, we do not. . .
Why is there a need to put the "symbolic content" into a file? How will this file be used?
You need to take the time to completely explain what you have and precisely what needs to be done with it.
Quote: |
My requirement is to column wise Print these Symbolic parameter into output file and other data. |
This will be best explained with the "rules" and examples. |
|
Back to top |
|
|
shivkumar
New User
Joined: 06 Mar 2009 Posts: 8 Location: Pune
|
|
|
|
Guys,
Sorry for lot of confusion for my post. Actually my requirement was to write a symbolic parameter content into file.
Example:
//STEP030 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=ZRP..C&YR.&MTH..C&CYCL.T&CTN..SV&PRCID,
// DISP=SHR
//SORTOUT DD DSN=ZRP..C&YR.&MTH..C&CYCL.T&CTN..SV&PRCID..SRTD1,
// DISP=(,CATLG,DELETE),
// SPACE=(CYL,(50,50),RLSE)
//SYSIN DD *
In above JCL ...I used input file as 'ZRP..C&YR.&MTH..C&CYCL.T&CTN..SV&PRCID'
At the time of execution, JCL will pick the symbolic parameter and read the input file as 'ZRP.C1007.C01T01.SVP020' .
My Requirement is to write ..1007 01 01 P020 in output file. |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
I still stand by my original answer. |
|
Back to top |
|
|
Arun Raj
Moderator
Joined: 17 Oct 2006 Posts: 2481 Location: @my desk
|
|
|
|
shivkumar wrote: |
At the time of execution, JCL will pick the symbolic parameter and read the input file as 'ZRP.C1007.C01T01.SVP020' . |
Are these symbolic values gonna be constant? If not, how does it get changed everytime when the job runs?
shivkumar wrote: |
My Requirement is to write ..1007 01 01 P020 in output file. |
Where and how this file is going to be used down the line? |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
shivkumar,
symbolic parameters are resolved by jes during initiation of job
but, symbolic parameters contained within a sysin, etc are not resolved.
As SuperK said, you need to write your own to do this.
suggest a google search on CLCCDSNS |
|
Back to top |
|
|
Pete Wilson
Active Member
Joined: 31 Dec 2009 Posts: 580 Location: London
|
|
|
|
could be a following REXX step to list matching files and pull the relevant bits from the list of dsnames returned into a file to pass on.... |
|
Back to top |
|
|
|