• Aucun résultat trouvé

IEBCOPY EXAMPLE 2

Dans le document MVS/370 Utilities (Page 85-91)

IEBCOPY EXAMPLE I

IEBCOPY EXAMPLE 2

The control statements are discussed below:

• INOUT4 DO defines a new partitioned data set (DATASET4) that is to be kept after the copy operation. Five tracks are allocated for the data set on a 3350 volume. Two blocks are allocated for directory entries.

• INOUTS DO defines a partitioned data set (DATASETS), that

depending on the amount of virtual storage available; therefore, the SYSUT3 and SYSUT4 DO statements should always appear in the

Output DATASET2

Before copy operation

Input DATASETl

After processing DATASET 1

Input DATASET6

After processing DATASET6

Input DATASET5

After processing DATASET5

Figure 24. Copying from Three Input Partitioned Data Sets

//COPY //JOBSTEP //SYSPRINT //INOUTI

/ /

//INOUT5

/ /

//INOUT2

/ /

//INOUT6

/ /

//SYSUT3 //SYSUT4 //SYSIN COPYOPER

64 MYS/370 Utilities

JOB EXEC DD DD DD DD DD DD DD DD COpy

PGM=IEBCOPY SYSOUT=A

DSNAME=DATASETl,UNIT=3330,YOL=SER=111112, DISP=SHR

DSNAME=DATASET5,UNIT=3350,YOl=SER=111114, DISP=OlD

DSNAME=DATASET2,UNIT=3350,YOL=SER=111115, DISP=(OlD,KEEP)

DSNAME=DATASET6,UNIT=3350,YOL=SER=111117, DISP=(OLD,DELETE)

UNIT=SYSDA,SPACE=(TRK,(l»

UNIT=SYSDA,SPACE=(TRK,(l»

*

OUTDD=INOUT2 INDD=INOUTI INDD=INOUT6 INDD=INOUT5

IEBCOPY EXAMPLE 3

The control statements are discussed below:

• INOUT1 DD defines a partitioned data set (DATASET1). This data set, which resides on a 3330 volume, contains three members (A, B, and F) in fixed format with a logical record

length of 80 bytes and a block size of 80 bytes.

• INOUT5 DD defines a partitioned data set (DATASET5), which resides on a 3350 volume. This data set contains two members (A and C) in fixed blocked format with a logical record length of 80 bytes and a block size of 160 bytes.

• INOUT2 DD defines a partitioned data set (OATASET2), which resides on a 3350 volume. This data set contains two

members (C and E) in fixed blocked format. The members have a logical record length of 80 bytes and a block size of 240 bytes.

• INOUT6 DO defines a partitioned data set (OATASET6), which resides on a 3350 volume. This data set contains three members (B, C, and D) in fixed-block format with a logical record length of 80 bytes and a block size of 400 bytes.

This data set is to be deleted when processing is completed.

• SYSUT3 DD defines a temporary spill data set. One track is allocated on a disk volume.

• SYSUT4 DD defines a temporary spill data set. One track is allocated on a disk volume.

• SYSIN DD defines the ~ontrol data set, which follows in the input stream. The data set contains a COpy statement and three INDD statements.

• COPY indicates the start of the copy operation. The absence of a SELECT or EXCLUDE statement causes a default to a full copy. The OUTDD parameter specifies INOUT2 as the DD

statement for the output data set (DATASET2).

• The first INDD statement specifies INOUT1 as the DD statement for the first input data set (DATASET1) to be processed. All members (A, B, and F) are copied to the output data set (DATASET2).

• The second INDD statement specifies INOUT6 as the DD statement for the second input data set (DATASET6) to be processed. Processing occurs, as follows: (1) members Band C, which already exist on DATASET2, are not copied to the output data set (DATASET2), (2) member D is copied to the output data set (DATASET2), and (3) all members on DATASET6 are lost when the data set is deleted.

• The third INDD statement specifies INOUT5 as the DD statement for the third input data set (DATASET5) to be processed. No members are copied to the output data set (DATASET2) because all of them exist on DATASET2.

The temporary spill data sets mayor may not be opened,

depending on the amount of virtual storage available; therefore, the SYSUT3 and SYSUT4 DD statements should always appear in the job stream.

In this example, members are copied from an input partitioned data set (DATASET6) to an existing output partitioned data set (DATASET2). In addition, all copied members replace identically

Inpul DATASU'

Output DATASET2

Alter prOClS$ing DATASET6

Figure 25. Copy Operation with "Replace" Specified on the Data Set level

The example follows:

.I.1COPY .I.1JOBSTEP .I.1SYSPRINT .I.1INOUT2

.1.1

.I.1INOUT6

.1.1

.I.1SYSUT3 .I.1SYSUT4 .I/SYSIN COPYOPER

.1*

66 MYS/370 Utilities

JOB EXEC DO DD DO DD DO DO COPY

PGM=IEBCOPY SYSOUT=A

OSNAME=DATASET2,UHIT=3330-1,YOl=SER=111113, OISP=OLD

OSNAME=DATASET6,UNIT=3350,YOL=SER=111117, OISP=(OLD,KEEP)

UNIT=SYSOA,SPACE=(TRK,(l»

UNIT=SYSDA,SPACE=(TRK,(l»

*

OUTDO=INOUT2 INDO=(CINOUT6,R»

IEBCOPY EXAMPLE 4

The control statements are discussed below:

• INOUT2 00 defines a partitioned data set (OATASET2), which

depending on the amount of virtual storage available; therefore, the SYSUT3 and SYSUT4 DO statements should always appear in the and after processing.

//COPY

Output DATAsET4

Before copy operatIon

Input DATASET 6

After prOCesSIng OATAsET6

Dis first

Input DATASET 2

After processing DATASET 2

Figure 26. Copying Selected Members with Reblocking and Deblocking

The control statements are discussed below:

• INOUT2 DD defines a partitioned data set (DATASET2), which resides on a 3330 volume. This data set contains two

members (C AND E) in variable-blocked format with a logical record length of 96 bytes and a block size of 500 bytes.

This data set is to be deleted when processing is completed.

• INOUT6 DD defines a partitioned data set (DATASET6), which resides on a 3350 volume. This data set contains three members (8, C, and D) in variable-blocked format with a logical record length of 96 bytes and a block size of 100 bytes.

• INOUT4 DD defines a partitioned data set (DATASET4). This data set is new and is to be kept after the copy operation.

Five tracks are allocated for the data set on a 3350 volume.

Two blocks are allocated for directory entries. In addition, records are to be copied to this data set in variable blocked format with a logical record length of 96 bytes and a block size of 300 bytes.

• SYSUT3 DD defines a temporary spill data set. One track is allocated on a disk volume.

68 MVS/370 Utilities

Dans le document MVS/370 Utilities (Page 85-91)