For OS/390 QSAM files, both fixed-length and variable-length, you can specify a configuration file on the OS/390 platform to set certain file creation characteristics. Indicate the location of this file with the -P
collector parameter.
You can also specify QSAM file creation characteristics using the RMTBATCH
Extract program parameter. The syntax is:
RMTBATCH file_spec, option [, option, ...];
file_spec
A file name or wildcard for the incoming file. Any files that match file_spec
are assigned the file creation rules you specify with option
. If a file name is satisfied by more than one RMTBATCH
entry in the configuration file, the last entry is used.
option
One of the following.
CLOSEACTION
"system_command
"Submits a shell script or system command to the system upon file close, when close was a result of completed processing of the corresponding source file (indicated by a "file close on source" message).
The Collector waits for the command to complete. To return control to the Collector immediately, specify a "nowait" type operation in the script or command (as with the &
in UNIX).
COMMENT
Lets you insert comments. Anything on the same line after COMMENT
is ignored. Comments can also begin with two hyphens (--).
SPACE
(primary_quantity
, secondary_quantity
, unit
)Mandatory parameter. Requests space for a new data set.
TARGETFTYPE {QSAMV | QSAMF}
Mandatory parameter for QSAM files. Specify QSAMV
for variable-length MVS QSAM files or QSAMF
for fixed-length MVS QSAM files.
TARGETRECLEN
record_length
Mandatory parameter for QSAM files. Specify the length in bytes of a fixed-length record or the maximum length in bytes for variable-length records. record_length
can be from 1
to 32760
.
TARGETBLKSIZE
block_length
Parameter for QSAM files. Specify a multiple of the record length for fixed-length records, or the maximum record length +4 for variable-length records. block_length
can be from 1 to 32760.
VOLUME
serial_number
Mandatory parameter. Identifies the serial number of the volume on which the target data set will reside. Specify only one volume serial number.
Example
The following example matches all source file names. It creates fixed length records of 100
bytes, in blocks of 1000
bytes (10 records per block), with a volume serial number for the new data set of 123456
, and allocates an initial space of 20
tracks. If more space is needed, it is allocated in increments of 10
tracks.
RMTBATCH *, TARGETFTYPE QSAMF, TARGETRECLEN 100, TARGETBLKSIZE 1000, VOLUME 123456, SPACE (20,10,TRK), CLOSEACTION "type * %";