List -

I am having a discussion on how a GDG is handled based on the DISP.  I was
always working from the position that the use of MOD changes JCL behavior
slightly with a dataset.  My understanding is:  If using MOD then if the dataset
does not exist, it is treated as NEW and if it exists then treated as OLD.  That
seems reasonable, however, I have some users coding this for GDGs and I am not
sure why they should work.


Now the following are samples and I am sure there are other coding that I have
not included.



So based on the following, which should be considered incorrect coding

1) First time creating the new Daily dataset.  There is also a concern on the
second coding


    //SMFOUT DD DSN=SMFHLQ.DAILY.SMFDSN(+1),   
    // DISP=(MOD,CATLG,DELETE), 
    // STORCLAS=NONSMS,EXPDT=99000, 
    // RECFM=VBS,BLKSIZE=32000,LRECL=32760,BUFNO=10, 
    // UNIT=TAPE 
    *** WARN 04: DISP FOR NEW GDG DATASET IS NOT (NEW,CATLG) 

Appending SMF data daily dataset

    //SMFOUT DD DSN=SMFHLQ.DAILY.SMFDSN(0),   
    // DISP=(MOD,CATLG,DELETE 
    *** WARN 04: DISP FOR NEW GDG DATASET IS NOT (NEW,CATLG)



2)  Using BR14 with MOD DELETE for a GEN that has NOT been created

    //S1 EXEC PGM=IEFBR14 
    //GDGBASE DD
DISP=(MOD,DELETE,DELETE),DSN=TSOHLQ.GDGTEST(0),SPACE=(TRK,(1,1)),UNIT=SYSDA
    !!!ERROR 04: GDG(0) NOT PERMITTED WITH DISP=NEW 


GDG does not have any GENs yet.  So get the following

    //COPYIT1 EXEC PGM=IEBGENER 
    //SYSPRINT DD SYSOUT=* 
    //* 
    //* 
    //SYSIN DD DUMMY 
    //SYSUT2 DD DISP=(MOD,CATLG,DELETE),UNIT=SYSDA,  
    // SPACE=(CYL,(1,1),RLSE), 
    // DSN=TSOHLQ.GDGTEST(+1)   
    *** WARN 04: DISP FOR NEW GDG DATASET IS NOT (NEW,CATLG)  
    //SYSUT1 DD * 
     TEST RECORD 


The GDG has one generation in the base I am able to see this should work

   //****************************************************************
   //* 
   //****************************************************************
   //S1 EXEC PGM=IEFBR14 
   //GDGBASE DD DISP=(MOD,DELETE,DELETE),DSN=TSOHLQ.GDGTEST(0) 


I am not saying these are great ways to code DISP=MOD, just that I have seen
this coding work but have been told that they should not work or they would
cause weird/crazy results


Any and all opinions welcome.



Thanks


Lizette Koehler
statistics: A precise and logical method for stating a half-truth inaccurately

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to