View previous topic :: View next topic |
Author |
Message |
Siddheart22 Beginner
Joined: 11 Apr 2005 Posts: 42 Topics: 19 Location: India
|
Posted: Tue Sep 12, 2006 12:43 am Post subject: Nested Cataloged Procedures |
|
|
Hi,
I am trying to learn the JCL concepts and have attempted to write a JCL which calls a cataloged procedure (PROC1). This procedure inturns calls another procedure (PROC2). Both PROC1 & PROC2 reside in EDUC122.PUNE.JCL1 PDS.
Within PROC2, I have only one step which executes IEFBR14. Note, there is only one SYSOUT DD statement in that step.
Please find the JCL attached below for reference:
Code: |
JOB:
//EDUC122R JOB ACCT#,'IBM ',MSGLEVEL=(1,1),
// NOTIFY=&SYSUID,REGION=2M
// JCLLIB ORDER=EDUC122.PUNE.JCL1
//STEP1 EXEC PROC1
PROC1:
//PROC1 PROC
//STEP2 EXEC PROC2
PROC2:
//PROC2 PROC
//STEP EXEC PGM=IEFBR14
//SYSOUT DD SYSOUT=*
|
When I submit this job, automatically SYSIN is added to the job as follows:
//SYSIN DD * GENERATED STATEMENT
I can view the above line in JESJCL.
Could you please advise on why has SYSIN been added automatically to my JOB?
Is it necessary for a PROC to have a SYSIN DD statement of it to be called from another PROC?
Thanks,
Sid. |
|
Back to top |
|
|
Cogito-Ergo-Sum Advanced
Joined: 15 Dec 2002 Posts: 637 Topics: 43 Location: Bengaluru, INDIA
|
Posted: Tue Sep 12, 2006 1:55 am Post subject: |
|
|
Where exactly is the SYSIN inserted ? Are you submitting using the SUB command or are you using Control-M, etc. ? _________________ ALL opinions are welcome.
Debugging tip:
When you have eliminated all which is impossible, then whatever remains, however improbable, must be the truth.
-- Sherlock Holmes. |
|
Back to top |
|
|
Siddheart22 Beginner
Joined: 11 Apr 2005 Posts: 42 Topics: 19 Location: India
|
Posted: Tue Sep 12, 2006 2:19 am Post subject: Nested Cataloged Procedures |
|
|
Cognito,
1. SYSIN DD statement is inserted at the end of the JOB.
2. I am using SUB to submit my job.
Sid. |
|
Back to top |
|
|
kolusu Site Admin
Joined: 26 Nov 2002 Posts: 12375 Topics: 75 Location: San Jose
|
Posted: Tue Sep 12, 2006 4:41 am Post subject: |
|
|
Siddheart22,
Most shops have automatic insert of SYSIN DD statement. So if your Job does not contain a sysin statement it will insert one.
Btw a sysin statement is not necessary at all.
Hope this helps...
Cheers
Kolusu _________________ Kolusu
www.linkedin.com/in/kolusu |
|
Back to top |
|
|
Siddheart22 Beginner
Joined: 11 Apr 2005 Posts: 42 Topics: 19 Location: India
|
Posted: Tue Sep 12, 2006 6:31 am Post subject: Nested Cataloged Procedures |
|
|
Kolusu,
The below content is of my job's JESJCL:
Note: The last statement (Statement #11) is auto-generated SYSIN statement.
Code: |
1 //EDUC122R JOB ACCT#,'IBM ',MSGLEVEL=(1,1),
// NOTIFY=&SYSUID,REGION=2M
2 // JCLLIB ORDER=EDUC122.PUNE.JCL1
3 //STEP1 EXEC PROC1
4 XXPROC1 PROC
5 XXSTEP3 EXEC PROC2
6 XXPROC2 PROC
7 XXSTEP EXEC PGM=IEFBR14
8 XXSYSOUT DD SYSOUT=*
9 XX PEND
10 XX PEND
11 //SYSIN DD * GENERATED STATEMENT
|
This Job is giving me a JCL error, I am cut-pasting error given in JESYSMSG here:
Code: |
11 IEFC611I OVERRIDDEN STEP NOT FOUND IN PROCEDURE
|
How can I get away with this JCL error?
Sid. |
|
Back to top |
|
|
Cogito-Ergo-Sum Advanced
Joined: 15 Dec 2002 Posts: 637 Topics: 43 Location: Bengaluru, INDIA
|
Posted: Tue Sep 12, 2006 6:39 am Post subject: |
|
|
Try coding EXEC PGM=IEFBR14 after you have invoked the outer PROC.... _________________ ALL opinions are welcome.
Debugging tip:
When you have eliminated all which is impossible, then whatever remains, however improbable, must be the truth.
-- Sherlock Holmes. |
|
Back to top |
|
|
Siddheart22 Beginner
Joined: 11 Apr 2005 Posts: 42 Topics: 19 Location: India
|
Posted: Thu Sep 14, 2006 1:15 am Post subject: Nested Cataloged Procedures |
|
|
Cogito,
Thanks for your suggestion.
While I was trying to resolve my error, by adding or removing or swapping some of my JCL statements with an intention to make it work, Before I could try your suggestion, I just thought of re-submitting the job as it is (i.e. as shown in my first post on this topic,refer below) and surprisingly the Job ran fine.
Earlier my question was, does the inner PROC (PROC2 in my case) require a SYSIN statement?
Now, I have one more question: Why did my JCL run with MAXCC=0 after several trials despite missing the SYSIN statement in my JCL?
All inputs are appreciated.
Thanks,
Sid. |
|
Back to top |
|
|
|
|