Page 1 of 1

JCL ERROR CN(INTERNAL)

PostPosted: Mon Mar 10, 2014 6:31 am
by Peroni
Hi everyone i'm fairly new to this and i'm currently learning how to use COBOL. This is my first attempt at this
I have came across this error JCL ERROR CN(INTERNAL) once I submit my job
 000100 //T03JOB1  JOB 1,NOTIFY=&SYSUID                     
 000200 //STEP1    EXEC PGM=ONE                             
 000300 //SYSUT1   DD DSN=&SYSUID..CW.DATA(T01),DISP=SHR   
 000400 //SYSUT2   DD DSN=&SYSUID..CW.OUTPUT(T01),DISP=SHR 
 000500 //SYSPRINT DD DUMMY                                 
 000600 //SYSIN    DD DUMMY                                 
 000700 // IF RC EQ 0 THEN                                 
 000800 //STEP2    EXEC PGM=TWO                             
 000900 //SYSUT1   DD DSN=&SYSUID..CW.DATA(T02),DISP=SHR   
 001000 //SYSUT2   DD DSN=&SYSUID..CW.OUTPUT(T02),DISP=SHR 
 001100 //SYSPRINT DD DUMMY                                 
 001200 //SYSIN    DD DUMMY                                 
 001300 // ELSE                                             
 001310 // IF RC > 0 THEN                                   
 001400 //STEP3    EXEC PGM=THREE                           
 001410 //SYSUT1   DD DSN=&SYSUID..CW.DATA(T02),DISP=SHR   
 001420 //SYSUT2   DD DSN=&SYSUID..CW.DATA(T02),DISP=SHR
 001430 //SYSPRINT DD DUMMY       
 001440 //SYSIN    DD DUMMY       
 001500 // ENDIF                   
 001600 /*                           


I've probably made a ton of mistakes I just wish it would tell me where so I could rectify them :oops:
Also i'd appreciate it if you could point me in the direction of some good reading materials thanks :)

Re: JCL ERROR CN(INTERNAL)

PostPosted: Mon Mar 10, 2014 6:54 am
by BillyBoyo
File 2 on the spool, the JESJCL, is what we need to see. That is where you will see the actual error(s) listed. If you can't crack it that way, post it here.

Re: JCL ERROR CN(INTERNAL)

PostPosted: Mon Mar 10, 2014 7:03 am
by Peroni
Thanks for the reply Billy, I'm not too sure if i'm in the right place but I can see this currently when I look at file 2 on the spool
The following data set was being edited or viewed when a system failure
or task abend occurred
Then it links T03

Re: JCL ERROR CN(INTERNAL)

PostPosted: Mon Mar 10, 2014 8:34 am
by steve-myers
Peroni wrote:Hi everyone i'm fairly new to this and i'm currently learning how to use COBOL. This is my first attempt at this
I have came across this error JCL ERROR CN(INTERNAL) once I submit my job
 000100 //T03JOB1  JOB 1,NOTIFY=&SYSUID                     
 000200 //STEP1    EXEC PGM=ONE                             
 000300 //SYSUT1   DD DSN=&SYSUID..CW.DATA(T01),DISP=SHR   
 000400 //SYSUT2   DD DSN=&SYSUID..CW.OUTPUT(T01),DISP=SHR 
 000500 //SYSPRINT DD DUMMY                                 
 000600 //SYSIN    DD DUMMY                                 
 000700 // IF RC EQ 0 THEN                                 
 000800 //STEP2    EXEC PGM=TWO                             
 000900 //SYSUT1   DD DSN=&SYSUID..CW.DATA(T02),DISP=SHR   
 001000 //SYSUT2   DD DSN=&SYSUID..CW.OUTPUT(T02),DISP=SHR 
 001100 //SYSPRINT DD DUMMY                                 
 001200 //SYSIN    DD DUMMY                                 
 001300 // ELSE                                             
 001310 // IF RC > 0 THEN                                   
 001400 //STEP3    EXEC PGM=THREE                           
 001410 //SYSUT1   DD DSN=&SYSUID..CW.DATA(T02),DISP=SHR   
 001420 //SYSUT2   DD DSN=&SYSUID..CW.DATA(T02),DISP=SHR
 001430 //SYSPRINT DD DUMMY       
 001440 //SYSIN    DD DUMMY       
 001500 // ENDIF                   
 001600 /*                           


I've probably made a ton of mistakes I just wish it would tell me where so I could rectify them :oops:
Also i'd appreciate it if you could point me in the direction of some good reading materials thanks :)
You need to study the chapter "IF/THEN/ELSE/ENDIF Statement Construct" in the MVS JCL Reference manual for your z/OS release. Two hints: each // IF JCL statement requires a // ENDIF statement, and I think (but I'm not certain) the /* statement at the end will cause an error.

Re: JCL ERROR CN(INTERNAL)

PostPosted: Mon Mar 10, 2014 1:32 pm
by Peroni
Thanks Steve, I will definitely read up on that and try and solve this problem myself. I will post the results once I get the thing working.

Re: JCL ERROR CN(INTERNAL)

PostPosted: Mon Mar 10, 2014 3:07 pm
by NicC
/* is the standard 'end of jobstream' for when jobs were punched cards read on a card reader. A following jobcard would also act in the same way.

Re: JCL ERROR CN(INTERNAL)

PostPosted: Mon Mar 10, 2014 4:10 pm
by Akatsukami
Does not /* signify "end of in-stream data" rather than "end of job"?

Re: JCL ERROR CN(INTERNAL)

PostPosted: Mon Mar 10, 2014 7:54 pm
by NicC
Akatsukami wrote:Does not /* signify "end of in-stream data" rather than "end of job"?

Actually, coming to think a bit more clearly now that we are past lunchtime, // is the EOJ marker. However /* does not hurt or issue any message - at least on our system it doesn't.

Re: JCL ERROR CN(INTERNAL)

PostPosted: Tue Mar 11, 2014 11:06 am
by steve-myers
NicC wrote:
Akatsukami wrote:Does not /* signify "end of in-stream data" rather than "end of job"?

Actually, coming to think a bit more clearly now that we are past lunchtime, // is the EOJ marker. However /* does not hurt or issue any message - at least on our system it doesn't.
A /* indicates the end of an in-stream data set; a // with nothing else on it is a fairly traditional end of job. My thought with the /* is it implies an in-stream data set, and JES might very well generate a //SYSIN DD * to start the data set. I didn't want to experiment, and it seemed fishy to me anyway.