1.Allocating a single-step temporary data set (a work file) Example 1 //WORK1 DD UNIT=SYSDA,SPACE=(CYL,(10,5)) Allocates a temporary ...
1.Allocating a single-step temporary data set (a work file)
Example 1
//WORK1 DD UNIT=SYSDA,SPACE=(CYL,(10,5))
Allocates a temporary data set on a SYSDA volume using 10 cylinders of primary and 5 cylinders of secondary space. DISP=(NEW,DELETE) is assumed.
Example 2
//WORK2 DD UNIT=SYSDA,DISP=(NEW,DELETE),
// SPACE=(3200,(500,500)),
// DCB=LRECL=120
Allocates a temporary data set on a SYSDA volume using 500 blocks of primary and secondary space. DISP=(NEW,DELETE) is specified, but could be omitted since it’s the default. The record length is 120 bytes.
2.A two-step job that uses temporary data sets
//MM01RN JOB (36512),'R MENENDEZ',MSGCLASS=X,MSGLEVEL=(1,1),
// CLASS=A,NOTIFY=&SYSUID
//SORT EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD DSNAME=MMA2.AR.CUSTOMER.MASTER,DISP=SHR
//SORTWK01 DD UNIT=SYSDA,SPACE=(TRK,(1,1))
//SORTWK02 DD UNIT=SYSDA,SPACE=(TRK,(1,1))
//SORTWK03 DD UNIT=SYSDA,SPACE=(TRK,(1,1))
//SORTOUT DD DSNAME=&&SORTCUST,DISP=(NEW,PASS),
// UNIT=SYSDA,SPACE=(TRK,(1,1))
//SYSIN DD *
SORT FIELDS=(2,13,A,20,1,A),FORMAT=CH
/*
//REPORT EXEC PGM=CUSTLST
//SYSOUT DD SYSOUT=*
//CUSTMAST DD DSNAME=&&SORTCUST,DISP=(OLD,DELETE)
//ATB DD SYSOUT=*
//SYSUDUMP DD SYSOUT=*
3.Examples of VIO temporary data sets
Example 1
//TEMP1 DD UNIT=VIO
The data set is defined as a VIO temporary work file that’s deleted at the end of the job step.
Example 2
//DD1 DD UNIT=SYSDA,SPACE=(1000,(10,50)),
// DCB=(RECFM=FB,LRECL=40)
If enough VIO space is available during the execution of the job step, the system will define the file as a VIO temporary data set. Otherwise, it’ll be defined as a DASD temporary data set. In either case, it’s deleted at the end of the job step.
Example 3
//SORTOUT DD DSNAME=&&PRODCD,DISP=(NEW,PASS),
// UNIT=SYSDA,SPACE=(1000,(20,70))
&&PRODCD will be defined as a VIO or DASD temporary data set, depending on the available VIO space. In either case, DISP=(NEW,PASS) will allow the data set to be available to subsequent job steps.
4.Allocating a dummy data set
Example 1
//SYSIN DD DUMMY
Allocates a dummy data set. OS/390 simulates input and output processing, but no I/O operations are actually performed.
Example 2
//CUSTMAST DD DUMMY,AMP=AMORG
Allocates a dummy VSAM data set.
Example 3
//TRANFILE DD DUMMY,DSNAME=AR.TRANS.FILE,DISP=(NEW,KEEP),
// UNIT=SYSDA,VOL=SER=MPS800,
// SPACE=(CYL,(5,1)),
// DCB=(DSORG=PS,RECFM=FB,LRECL=80)
Allocates a dummy data set using the specified file characteristics. When the DUMMY parameter is removed, this DD statement will allocate an actual data set.
Example 4
//TRANFILE DD DSNAME=NULLFILE,DISP=(NEW,KEEP),
// UNIT=SYSDA,VOL=SER=MPS800,
// SPACE=(CYL,(5,1)),
// DCB=(DSORG=PS,RECFM=FB,LRECL=80)
Allocates a dummy data set using the specified file characteristics. When NULLFILE is changed to a data set name, this DD statement will allocate an actual data set.
No comments
Post a Comment