CICS® supports
access to keyed and nonkeyed BDAM data sets. To construct and format such
data sets, you use BDAM.
About this task
A BDAM data set must contain data before it is used in a CICS run. You load the data set using a batch program that writes the records sequentially. An example of this is Figure 1. Figure 1. Sample JCL to create and load a BDAM data set
The input data set (called SYSUT1 in this example) should be physically
sequential and have attributes that are compatible with the DCB for the output
data set (called SYSUT2 in this example; see note 3). In particular:
If RECFM=F is specified for the output data set, then the input data set
must have RECFM=F or RECFM=FB specified, and the value of LRECL should be
the same for both data sets.
If RECFM=V or RECFM=U is specified for the output data set, then the value
of LRECL for the input data set must not be greater than that specified on
the output data set.
When you create a data set, you define a data set name (DSNAME) of up
to 44 characters. This data set name uniquely identifies the data set to your MVS system.
The DCB parameter for the output data set should specify the following:
DSORG=DA. This identifies the data set as a BDAM data set.
BLKSIZE. This should have the same value as specified for BLKSIZE in the
associated file control table (FCT) entry.
RECFM. This can take the values F (fixed), V (variable), or U (undefined),
and correspond to the first subparameter of the RECFORM operand in the associated
FCT entry.
These options are specified on the DFHFCT TYPE=FILE definition. File control table (FCT) gives information about defining files using DFHFCT TYPE=FILE
options. A data set created by this example, and loaded with data such as that shown in Figure 2, would have the following attributes specified in its FCT entry:
BLKSIZE=80
LRECL=40
RECFORM=(FIXED BLOCKED)
KEYLEN=8
Figure 2. Sample data for loading a BDAM data set
RECORD 1 DATA FOR RECORD 1 RECORD 2 DATA FOR RECORD 2
RECORD 3 DATA FOR RECORD 3 RECORD 4 DATA FOR RECORD 4
RECORD98 DATA FOR RECORD 98 RECORD99 DATA FOR RECORD 99
1----+----2----+----3----+----4----+----5----+----6----+----7----+----8