View previous topic :: View next topic |
Author |
Message |
southskies Beginner
Joined: 14 Jul 2008 Posts: 9 Topics: 4
|
Posted: Tue Dec 14, 2010 9:38 am Post subject: TSO SUBMIT and JOBCHAR |
|
|
Hi,
If a jobs is submitted via the TSO SUBMIT <dsn> JOBCHAR(xy), is there any way that the value of the JOBCHAR parameter can be identified in the JCL at all? Is it given a variable name by any chance?
Within a PROC in the JCL I wish to pass this value. Looking for a simple solution, not wanting one using REXX or Skels. Simplicity is the key here. Our site has not been configured to have the correct value of &JOBNAME either - it is incorrectly set to have a value of JES2, not the actual job name
Thanks,
Steve |
|
Back to top |
|
|
kolusu Site Admin
Joined: 26 Nov 2002 Posts: 12376 Topics: 75 Location: San Jose
|
Posted: Tue Dec 14, 2010 2:23 pm Post subject: |
|
|
southskies,
AFAIK it is not possible to use a symbol for the Jobname. Why can't you generate the Jobcard before submitting the job?
Kolusu |
|
Back to top |
|
|
southskies Beginner
Joined: 14 Jul 2008 Posts: 9 Topics: 4
|
Posted: Tue Dec 14, 2010 6:09 pm Post subject: |
|
|
Hi Kolusu,
The jobname wasn't really the issue. I was wanting to be able to test or use the value of JOBCHAR in my job.
If it can't be tested, then why on earth was this functionality invented? To submit the same job over and over without altering any of the processing in the job?
Steve |
|
Back to top |
|
|
kolusu Site Admin
Joined: 26 Nov 2002 Posts: 12376 Topics: 75 Location: San Jose
|
Posted: Tue Dec 14, 2010 6:28 pm Post subject: |
|
|
southskies wrote: | Hi Kolusu,
The jobname wasn't really the issue. I was wanting to be able to test or use the value of JOBCHAR in my job.
If it can't be tested, then why on earth was this functionality invented? To submit the same job over and over without altering any of the processing in the job?
Steve |
Oh if you just want the jobname then it is very easy.
With z/OS DFSORT V1R10 PTF UK90025 or z/OS DFSORT V1R12 PTF UK90026 (Oct, 2010), you can now use DFSORT's new JP1 Symbols to pass parms to sort like shown below
Code: |
//STEP0100 EXEC PGM=SORT,PARM='JP1"&JOBNAME"'
//SYSOUT DD SYSOUT=*
//SORTIN DD *
//SORTOUT DD SYSOUT=*
//SYSIN DD *
SORT FIELDS=COPY
OUTFIL REMOVECC,
TRAILER1=('THE JOBNAME IS : ',JP1)
//* |
If you don't have the PTF installed you can use the following method using symnames.
Code: |
//STEP0100 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SYMNAMES DD *
CURRJOB,S'&JOBNAME'
//SORTIN DD *
//SORTOUT DD SYSOUT=*
//SYSIN DD *
SORT FIELDS=COPY
OUTFIL REMOVECC,
TRAILER1=('THE JOBNAME IS : ',CURRJOB)
//* |
The output will be 80 byte file with the following contents.
Code: |
THE JOBNAME IS : xxxxxxx
|
_________________ Kolusu
www.linkedin.com/in/kolusu |
|
Back to top |
|
|
|
|