View previous topic :: View next topic
|
Author |
Message |
nartcr
New User
Joined: 06 Jun 2007 Posts: 83 Location: anada
|
|
|
|
I have been trying to troubleshoot this from last many hours, any insight would be helpful for me at this stage. The issue i am facing is, when i execute the below JCL, the dataset ( X12EXT ) is getting created with ZERO records.
I have the following JCL:
Code: |
//TESTD37 EXEC PGM=TESTD37
//STEPLIB DD DSN=CMNP.RWIP0.P.X.TSTP.#002443.LDB,DISP=SHR
// DD DSN=CMNP.PLODB.P.TSTP.PROD,DISP=SHR
//TEMPDS DD DSN=TSTD.SAIFB.N.GAMEXT.F83H.G0016V00,DISP=SHR
//X12EXT DD DSN=VF0009.TEST.N.NARA.TST,
// DISP=(NEW,CATLG,DELETE),
// UNIT=SYSDA,SPACE=(CYL,(5,5),RLSE),
// DCB=(RECFM=VB,LRECL=254)
//SYSUDUMP DD SYSOUT=*
//SYSDBOUT DD SYSOUT=*
//SYSOUT DD SYSOUT=* |
This is my FD section for the above file.
Code: |
FILE SECTION.
FD TEMPDS-FILE
RECORDING MODE IS V
LABEL RECORDS STANDARD
BLOCK CONTAINS 0 RECORDS
RECORD IS VARYING IN SIZE FROM 1 TO 250 CHARACTERS.
01 TEMPDS-REC PIC X(250).
FD X12OUT-FILE
RECORDING MODE IS V
LABEL RECORDS STANDARD
BLOCK CONTAINS 0 RECORDS
RECORD IS VARYING IN SIZE FROM 1 TO 250 CHARACTERS.
01 X12OUT-REC PIC X(250). |
This is my write Para:
Code: |
150-WRITE-X12OUT-FILE.
DISPLAY 'NARA:' WS-X12OUT-RECORD.
WRITE X12OUT-REC FROM WS-X12OUT-RECORD.
ADD 1 TO OUT-REC-CNT.
150-WRITE-X12OUT-FILE-END.
EXIT. |
The display details are shown in SPOOL.
Code: |
NARA:TEST RECORD FOR CUSTOMER A
NARA:HELLO GOOD MORNING |
would someone be able to throw some insight to this? If you need more info, let me know.
Spool shows that the dataset was retained - and i couldnt find a trace of job not doing it.
Code: |
IEF142I TESTL9LF TESTD37 - STEP WAS EXECUTED - COND CODE 0000
IGD104I CMNP.RWIP0.P.X.TSTP.#002443.LDB RETAINED, DDNAME=STEPLIB
IGD104I CMNP.PLODB.P.TSTP.PROD RETAINED, DDNAME=
IGD104I TSTD.SAIFB.N.GAMEXT.F83H.G0016V00 RETAINED, DDNAME=TEMPDS
IGD104I VF0009.TEST.N.NARA.TST RETAINED, DDNAME=X12EXT |
|
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
1. your select statements
2. do you display OUT-REC-CNT at eoj?
3. what is the data definition of structure WS-X12OUT-RECORD
4. show us the ALLOCATE entries of the spool. (start of job)
your fd statements are TEMPDS and X12OUT,
why not X12EXT?
Quote: |
and i couldnt find a trace of job not doing it. |
what does this mean?
what is contained in ds VF0009.TEST.N.NARA.TST
why do you think this is a JCL issue and not COBOL? |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8696 Location: Dubuque, Iowa, USA
|
|
|
|
What is the file status code from the OPEN? WRITE?
What compile options are you using? |
|
Back to top |
|
|
nartcr
New User
Joined: 06 Jun 2007 Posts: 83 Location: anada
|
|
|
|
I feel like crying - Thanks a lot Dick.
"your fd statements are TEMPDS and X12OUT,
why not X12EXT? " was the reason. JCL was just allocating dataset, and wasnt doing anything further.
Thanks a lot for your response. |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
well, you are welcome,
BTW JCL does nothing other than communicate (via Job Control Language)
to the system,
what should be done.
then the system takes over,
and the individual parts of the system (services)
do things.
and,
as Robert implied,
you should start implementing files status codes,
and checking of the status code after every i/o request.
would have saved you some tears. |
|
Back to top |
|
|
|