16.12.2012 Views

z/OS V1R9.0 UNIX System Services Command ... - Christian Grothoff

z/OS V1R9.0 UNIX System Services Command ... - Christian Grothoff

z/OS V1R9.0 UNIX System Services Command ... - Christian Grothoff

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Return codes<br />

Examples<br />

– For an MVS data set in fixed record format: Data is cut into chunks of<br />

size equal to the record length. Each chunk is put into one record. The<br />

last record is padded with spaces or blanks.<br />

– For an MVS data set in variable record format: Data is cut into chunks<br />

of size equal to the largest record length. Each chunk is put into one<br />

record. The length of the last record is equal to the length of the data left.<br />

– For an MVS data set in undefined record format: Data is cut into<br />

chunks of size equal to the block size. Each chunk is put into one record.<br />

The length of the last record is equal to the length of the data left.<br />

7. When you copy MVS data sets to z/<strong>OS</strong> <strong>UNIX</strong> file system text files, a <br />

character is appended to the end of each record. If trailing blanks exist in the<br />

record, the character is appended after the trailing blanks.<br />

8. When you copy MVS data sets to z/<strong>OS</strong> <strong>UNIX</strong> file system binary files, the<br />

character is not appended to the record.<br />

0 Processing successful.<br />

12 Processing unsuccessful. An error message has been issued.<br />

1. The following commands copy an MVS sequential data set to an z/<strong>OS</strong> <strong>UNIX</strong> file<br />

system file. This is text data, and there is no code page conversion.<br />

v SYSUT1 is the ddname of the source data set, EMPLOYEE.DATA.<br />

v PATHNAME is the ddname of the target, which is the existing file<br />

/u/admin/employee/data.<br />

ALLOCATE FILE(sysut1) DATASET(’employee.data’)<br />

ALLOCATE FILE(pathname) PATH(’/u/admin/employee/data’)<br />

OCOPY INDD(sysut1) OUTDD(pathname) TEXT<br />

2. The following commands copy a binary file into a member of a partitioned data<br />

set:<br />

v BINARY is the ddname of the source file, bin/payroll. This file is in the<br />

working directory.<br />

v MVSPDS is the ddname of the target data set member,<br />

APPL.CODES(PAYROLL)<br />

ALLOCATE FILE(binary) PATH(’/bin/payroll’)<br />

ALLOCATE FILE(mvspds) DATASET(’appl.codes(payroll)’)<br />

OCOPY INDD(binary) OUTDD(mvspds) BINARY<br />

3. The following commands copy system input from the MVS SYSIN data set to<br />

the file system and perform code page conversion:<br />

v SYSIN is the ddname of the source, IBMUSR.EMPLOYEE.DATA.<br />

v PATHNAME is the ddname of the target, /u/admin/employee/data. This file<br />

does not currently exist and is created by ALLOCATE.<br />

v This is text data.<br />

v The character conversion table is the default table, member BPXFX000 of the<br />

SYS1.BPXLATE data set. (BPXFX000 is an alias; when shipped by IBM, it<br />

points to BPXFX111.)<br />

v Because this is a copy from an MVS data set to a file, the topic TO1047 of<br />

the conversion table is used by default.<br />

ALLOCATE FILE(sysin) DATASET(’IBMUSR.EMPLOYEE.DATA’)<br />

ALLOCATE FILE(pathname) PATH(’/u/admin/employee/data’)<br />

OCOPY<br />

Chapter 3. TSO/E commands 843

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!