Version 7.4.4

DATADEF Information For VM/GCS

The information in this section is applicable for Entire Net-Work systems that run in a z/VM / GCS environment.


DATADEF File Assignments

All assignments for files which are accessed by an Adabas nucleus or utility must be done using DATADEF which replaces the GCS FILEDEF command in the Adabas environment. DATADEF accepts parameters in the form of either a tokenized parameter list or an extended parameter list. The extended parameter list takes precedence. The file assignments established by the DATADEF statements can be listed using the DISPDD program.

The program RELDD can be used to clear active DATADEF entries. RELDD accepts a list of file names to be released or, if no list is specified, clears all active DATADEF entries.

The DATADEF statement creates a data definition block (DDB), which remains in system storage until it is either

The parameters for DATADEF consist of one positional parameter and one or more keyword parameters separated by commas. An equal sign (=) must be used between a keyword and the parameter value. Depending on how DATADEF is invoked, spaces may be required surrounding equal signs, commas, and parentheses.

The DATADEF parameters are described in the following table:

Parameter Keyword Required/ Optional Maximum Length Specifies . . .
positional Required 8 the file name (DD) names as specified in Adabas Operations or Adabas Utilities.
BUFNO Optional 3 (1 - 255) the number of buffers to be allocated for a sequential file on tape. Default: 3
COMPRESS Optional 53 (YES - NO) whether or not an output file on tape should make use of IDRC available on certain cassette units. If IDRC is not supported, this parameter is set to NO, the default.
CONCAT Optional 5 (1 - 255) a concatenation sequence number for the file. This results in the DDB being concatenated to another existing DDB with the same file name. The sequence numbers must be specified in ascending order with no numbers left out. The first file to be concatenated has the number 1. If specified for a file to be read backward, the sequence numbers are to be given in the normal sequential order. A DATADEF statement without CONCAT frees any existing root DDB and any DDBs concatenated to it.
DISP Optional for output only 3 whether a sequential file is to be created (NEW), extended (MOD) or overwritten (OLD). If NEW is specified and the file exists a return code is issued. If OLD is specified, the file’s existence is not checked. Default: OLD
DSN Required if not dummy 44 the dataset name.
DUMMY Optional - that the file does not exist. DUMMY is a keyword without a value. It may not be specified with any other parameter except file name.
EXTEND Optional - that an existing DDB is to be extended. EXTEND is a keyword without a value. It may only be specified with the file name, VOL, and UNIT parameters.
FILESEQ Tape only, optional 3 the sequence number of the file on a multi-file tape. The default value (1) is required if tapes are to be read backward.
FNAME Required if DSN is a SFS 8 the file name of an SFS member.
FTYPE Required if DSN is a SFS 8 the file type of an SFS member.
LRECL See note 2 5 the length of the physical blocks in the file. If RECFM=FB, BLKSIZE must be an integral multiple of LRECL; if RECFM=V or RECFM=VB, BLKSIZE must be equal to or more than LRECL + 4.
MODE See note 1 2 the z/VM filemode.
RECFM See note 2 2 the format of the records in the file (F, FB, V, VB, U).
UNLOAD Tape only, optional 3 (YES - NO) whether or not the tape is rewound and unloaded. If NO is specified, the tape is rewound at close but is not unloaded. Default: YES.
UNIT See notes 1 and 3 See note 1 a list of virtual addresses (cuu, or ccuu for XA) of the unit or units containing the file, or one of the logical device abbreviations: TRM, PUN, RDR, PRT, or SFS. If a unit address list is given, it must be enclosed in parentheses and entries must be separated by commas.
VOL See note 1 See note 1 a list of the serial numbers (each at most 6 characters) of the volumes containing the file; if multiple volumes are specified, they must be separated by commas and enclosed in parentheses.

Notes:

  1. A MODE parameter is required for sequential z/VM DASD files. For DASD volumes containing database files, either a VOL, UNIT, or MODE parameter is required. If the database file spans multiple volumes, VOL or UNIT must be specified. Specifying MODE=* for an non-existent file results in a return code of 32.

    If both VOL and UNIT are specified, the number of volumes and unit addresses must be equal and each volume in the VOL list must be mounted on the unit specified by the corresponding entry in the UNIT list (the first VOL entry must be mounted on the first UNIT entry, and so on).

    For tape files, a UNIT must be specified and a real unit attached prior to DATADEF execution, unless the tape unit is dynamically allocated at open time; in this case, TAPx can be specified according to standard z/VM conventions, where TAP1 specifies virtual unit 181, TAP2 specifies unit 182, and so on. Only one tape unit address is allowed in the UNIT parameter.

    The VOL parameter is required for input tape files, but is optional for output tape files. If a tape file spanning multiple volumes is to be read backwards, specify the volumes in the normal sequential order.

    When creating a multi-volume tape file, Adabas-z/VM maintains a list of the file volumes. To refer to that volume list in a later DATADEF, specify VOL=*filename where filename is the name of the multi-volume file.

  2. The parameters RECFM,LRECL, and BLKSIZE are required only for tape input files without a HDR2 label and for VSE sequential DASD files. If RECFM has been specified, the corresponding BLKSIZE and LRECL parameters are also required.

Top of page

DATADEF Error Codes

The following error codes may be returned by DATADEF:

Response Code Description
16 No parameter list was supplied
20 Invalid keyword
24 No file name specified
28 Error in DSN or DUMMY specification: neither a DSN nor DUMMY was specified; or conflicting parameter specification for a dummy file
32 Error in VOL, UNIT or MODE parameter
36 Incorrect length for VOL,UNIT or MODE parameter
40 Insufficient virtual storage
44 Internal error issuing a CP command
48 Invalid cuu address (internal error)
52 Volume or unit not available or non-VTOC volume has been attached
56 Database file resides on volumes with mixed formats (VTOC, non-VTOC)
60 Database file resides on volumes of different device types
64 More than one unit specified for a tape file
68 Invalid file sequence number
72 Invalid RECFM parameter
76 Invalid BLKSIZE parameter
80 Invalid LRECL parameter
84 Invalid DISP parameter
88 Invalid concatenation count
92 Invalid DDB extension

Top of page