Doug

You quoted the my previous post and you didn't retain my quoting of Paul's original post so your post is a bit difficult to follow by itself.

In fact, Paul's original post indicated that a data set which did *not* exist was kept although not actually created - and so the SPACE issue did not arise. It was this conundrum for which I made a hesitating attempt to try to provide a resolution.

If you've only just discovered this "trick" - pointed out to me many years ago by a guru from the Washington Systems Center - perhaps this example can show you how it may be used:

//NET PROC
//*
//IEFBR14 EXEC PGM=IEFBR14
//NCPDUMP DD DSN=USER.NCPDUMP,DISP=(MOD,DELETE),
// VOL=REF=SYS1.PARMLIB,SPACE=(TRK,1)
//*
//NET EXEC PGM=ISTINM01,TIME=1440,REGION=2048K
//STEPLIB DD DSN=SYS1.SSPLIB,DISP=SHR
//VTAMLST DD DSN=USER.VTAMLST,DISP=SHR
//VTAMLIB DD DSN=USER.VTAMLIB,DISP=SHR
//        DD DSN=SYS1.VTAMLIB,DISP=SHR
//NCPLOAD DD DSN=USER.NCPLOAD,DISP=SHR
//NCPDUMP DD DSN=USER.NCPDUMP,DISP=(NEW,KEEP),
// VOL=REF=SYS1.PARMLIB,SPACE=(TRK,(1,50),RLSE),
// DCB=(RECFM=F,LRECL=512,BLKSIZE=512)

It would appear that all the years I was using this "trick", I may not have needed the SPACE=(TRK,1) in the first step.

Note that I was obliged to include TIME=1440 on the EXEC statement since I was obliged to remove SYST from the SCHEDxx entry for ISTINM01.

Chris Mason

----- Original Message ----- From: "Doug Fuerst" <[EMAIL PROTECTED]>
Newsgroups: bit.listserv.ibm-main
To: <IBM-MAIN@BAMA.UA.EDU>
Sent: Wednesday, May 23, 2007 8:19 AM
Subject: Re: DISP=(MOD,DELETE)


Actually, this was recently explained to me by IBM. (MOD,DELETE) indicates that the dataset might exist, if it does, then MOD it. If it does not, then create it and then delete it. But SPACE would be required in any case where the dataset did not exist. This would also be true for (MOD,KEEP). In this case, if the dataset did not exist it would be created, and KEPT, but not cataloged. SPACE would be required if the dataset did not exist.

Doug



At 01:46 AM 5/23/2007, you wrote:
Paul

You got my attention with the subject line, DISP=(MOD,DELETE), since I used to encourage students to consider using this "trick" in order to immunise their JCL against irritating errors when they had usually started task procedures relating to networking products and they didn't care whether or not a data set existed when the task was started. The types of data sets involved were for traces, logs and dumps.

Typically the started task procedure had an IEFBR14 step where the data sets were definitely erased if they happened to exist - from, typically of course, any previous execution - using the DISP=(MOD,DELETE) "trick". The IEFBR14 step was then followed by the "business" step.[1]

What you show in fact is DISP=(MOD,KEEP).

An explanation - not at all necessarily *the* explanation since it's very much a guess - for the IEF285I message is that, with DISP=MOD, logically the data set is considered to exist and thus it can logically be "kept". However, with, DISP=NEW, the data set is considered *not* to exist - and you get another error presumably earlier in the processing sequence if it does exist - and so, before it can be "kept", it must actually be created. In order to be created, the SPACE parameters are needed.

So *I* understand it. Of course whether or not I understand it correctly is quite another thing!

Chris Mason

snip undone <<<<<

----- Original Message ----- From: "Paul Gilmartin" <[EMAIL PROTECTED]>
Newsgroups: bit.listserv.ibm-main
To: <IBM-MAIN@BAMA.UA.EDU>
Sent: Wednesday, May 23, 2007 12:05 AM
Subject: DISP=(MOD,DELETE)


The JCL fragment:

   //STEP     EXEC  PGM=IEFBR14
   //*
   //SYSUT1    DD   DSN=user.FOO.BAR.SMPLOG,DISP=(MOD,KEEP),
   //   VOL=SER=TSO026,
   //            UNIT=SYSALLDA

where 'user.FOO.BAR.SMPLOG' does not pre-exist on the volume
produces allocation messages:

IEF236I ALLOC. FOR MODKEEP STEP IEF237I 3ECA ALLOCATED TO SYSUT1 IEF142I MODKEEP STEP - STEP WAS EXECUTED - COND CODE 0000 IEF285I user.FOO.BAR.SMPLOG KEPT IEF285I VOL SER NOS= TSO026. IEF373I STEP/STEP /START 2007142.1554
... but VTOC listing does not show the data set.  As I read
the " 12.19.11 Summary of Disposition Processing" in the JCL
RM, I believe it should be kept.  When I change to DISP=(NEW,KEEP),
it fails with:

   IGD17045I SPACE NOT SPECIFIED FOR ALLOCATION OF DATA SET

Is this working as expected?  Should I be able to understand
this?

Thanks,
gil

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html

Reply via email to