IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Job doesn't abend for missing DD names


IBM Mainframe Forums -> ABENDS & Debugging
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
mdolia

New User


Joined: 12 Dec 2007
Posts: 3
Location: Bangalore

PostPosted: Tue Feb 03, 2009 7:31 pm
Reply with quote

I'm having a problem when executing a job with missing DD statements for COBOL program output files. The main program calls a sub-program where the output files are assigned to DD names.
The program doesn't abend even when there is no corresponding DD names defined for the output file.
I have also checked the compile/link-edit option if something needs to be changed with no luck!
Please help and provide your inputs

Thanks!
Back to top
View user's profile Send private message
superk

Global Moderator


Joined: 26 Apr 2004
Posts: 4652
Location: Raleigh, NC, USA

PostPosted: Tue Feb 03, 2009 7:34 pm
Reply with quote

My guess is that none of the programs ever attempted to open any of the output assignments pointing to the missing DD names.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8700
Location: Dubuque, Iowa, USA

PostPosted: Tue Feb 03, 2009 7:40 pm
Reply with quote

If the subprogram is COBOL, the files could be optional. Or as Kevin said the files were never used by the subprogram.
Back to top
View user's profile Send private message
mdolia

New User


Joined: 12 Dec 2007
Posts: 3
Location: Bangalore

PostPosted: Tue Feb 03, 2009 7:54 pm
Reply with quote

Hi Robert and Kevin,
Thanks for your reply. My requirement is to abend the job in case of missing DD names. The sub-program opens the output files that are pointing to the missing DDs. And even when I remove all the DD names of the ouput files defined in the sub-program, the sub-program doesn't abend.

Thanks!
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8700
Location: Dubuque, Iowa, USA

PostPosted: Tue Feb 03, 2009 8:00 pm
Reply with quote

Can you show us the JCL as expanded by JES? Which DD statements are being opened by the subprogram? What language is the subprogram in? How do you know for sure that the subprogram is actually opening the files? Are there any messages being generated by the job?
Back to top
View user's profile Send private message
mdolia

New User


Joined: 12 Dec 2007
Posts: 3
Location: Bangalore

PostPosted: Tue Feb 03, 2009 8:23 pm
Reply with quote

Hi Robert,

The JCL is below:(Please note I have commented the SYS020 and SYS021 DD names)
=================
//RB140 EXEC PGM=IKJEFT1A,DYNAMNBR=20
................
//SYSTSIN DD *
DSN SYSTEM (DB3)
RUN PROGRAM(RB140) PLAN(RB140)
END
//*
...............
//*SYS020 DD DSN=GP1390.TEST1,
//* UNIT=DISK,
//* DISP=(,CATLG,DELETE),
//* SPACE=(TRK,(300,100),RLSE),
//* DCB=(LRECL=1416,RECFM=VB)
//*
//*SYS021 DD DSN=GP1930.TEST2,
//* UNIT=DISK,
//* DISP=(,CATLG,DELETE),
//* SPACE=(TRK,(300,100),RLSE),
//* DCB=(LRECL=1416,RECFM=VB)
//*


The DD statements SYS020/SYS021 is defined in the sub-program as below:
FILE-CONTROL.
SELECT GIISAP01 ASSIGN UT-S-SYS020 FILE STATUS GIISAP01-STAT.
SELECT GIISAP02 ASSIGN UT-S-SYS021 FILE STATUS GIISAP02-STAT.

The sub-program is opening the files in this manner:
A050-OPEN-GIISAP SECTION.
OPEN OUTPUT GIISAP01.
OPEN OUTPUT GIISAP02.

The sub-program is also written in purely COBOL.

These are the some messages generated by the job for the above DD names:
PGM=RB140M25 ---> Sub-program
IGD101I SMS ALLOCATED TO DDNAME (SYS020 )
DSN (SYS09034.T153706.RA000.GP4090V3.R0173129 )
STORCLAS (SCTEMP) MGMTCLAS ( ) DATACLAS ( )
VOL SER NOS= VIO
IGD101I SMS ALLOCATED TO DDNAME (DR#00001)
DSN (RE.T153706.RB1400T.L01NSW.PNK1TD.FT100 )
STORCLAS (SCPROD) MGMTCLAS (D07KNNY) DATACLAS ( )
VOL SER NOS= PR0380
DB9005 TAB NFNDS120 DEBIT/CR HKONT: A9999997 WERTT: PA
IGD101I SMS ALLOCATED TO DDNAME (SYS021 )
DSN (SYS09034.T153714.RA000.GP4090V3.R0173132 )
STORCLAS (SCTEMP) MGMTCLAS ( ) DATACLAS ( )
VOL SER NOS= VIO

My doubt is even when I remove the corresponding SYS020/SYS021 DD names, the JCL doesnot abend.
And my requirement is to abend the JCL in case if any DD names are missing corresponding to the output files.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8700
Location: Dubuque, Iowa, USA

PostPosted: Tue Feb 03, 2009 8:32 pm
Reply with quote

Code:
PGM=RB140M25 ---> Sub-program
IGD101I SMS ALLOCATED TO DDNAME (SYS020 )
DSN (SYS09034.T153706.RA000.GP4090V3.R0173129 )
STORCLAS (SCTEMP) MGMTCLAS ( ) DATACLAS ( )
VOL SER NOS= VIO
IGD101I SMS ALLOCATED TO DDNAME (DR#00001)
DSN (RE.T153706.RB1400T.L01NSW.PNK1TD.FT100 )
STORCLAS (SCPROD) MGMTCLAS (D07KNNY) DATACLAS ( )
VOL SER NOS= PR0380
DB9005 TAB NFNDS120 DEBIT/CR HKONT: A9999997 WERTT: PA
IGD101I SMS ALLOCATED TO DDNAME (SYS021 )
DSN (SYS09034.T153714.RA000.GP4090V3.R0173132 )
STORCLAS (SCTEMP) MGMTCLAS ( ) DATACLAS ( )
VOL SER NOS= VIO
These messages are saying your DD names are being dynamically allocated to VIO datasets. You need to get with your systems support people to find out how to abend instead of dynamically allocating files.
Back to top
View user's profile Send private message
Ajay Baghel

Active User


Joined: 25 Apr 2007
Posts: 206
Location: Bangalore

PostPosted: Tue Feb 03, 2009 10:17 pm
Reply with quote

Hi Robert,

How can we decide/specify thru the cobol program in order to dynamically allocate vio datasets ?

I mean, looking at the below statement in OP's code
Code:
SELECT GIISAP01 ASSIGN UT-S-SYS020 FILE STATUS GIISAP01-STAT.
SELECT GIISAP02 ASSIGN UT-S-SYS021 FILE STATUS GIISAP02-STAT.


It looks same like we would code for allocating a normal dataset.

Thanks,
Ajay
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8700
Location: Dubuque, Iowa, USA

PostPosted: Tue Feb 03, 2009 11:36 pm
Reply with quote

This is not a COBOL issue. It is a systems issue which requires your systems support people to be involved. They need to tell you how to set up your DD statement to not automatically allocate a file if the DD name is missing.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> ABENDS & Debugging

 


Similar Topics
Topic Forum Replies
No new posts Call an hlasm from REXX in batch and ... CLIST & REXX 4
No new posts What is the most complex abend you've... Mainframe Interview Questions 8
No new posts ISAM and abend S03B JCL & VSAM 10
No new posts Abend S0C4 11 (Page Translation Excep... PL/I & Assembler 16
No new posts Capturing COBOL job and program names... All Other Mainframe Topics 2
Search our Forums:

Back to Top