bdfd1m12Database Administration

Creating a DBDEF Macro Definition

The DBDEF macro (along with the DSECT macro) defines the characteristics of a file; for example, whether the file uses an algorithm, indexed files, B+Tree indexing, or a combination of attributes. Segments UF2A-UF89 are reserved for customer DBDEF macro statements. To use the DBDEF macro statements that you code in these segments, include ENTRC statements in case 1 of the DFUEX segment. For example, if you have DBDEF macro statements coded in UF2A and UF2F, include the following statements in DFUEX:

   ENTRC UF2A                USER SPECIFIC DB DEFINITIONS FOR UF2A
   BR    R7                  RETURN TO ROUTINE
   ENTRC UF2F                USER SPECIFIC DB DEFINITIONS FOR UF2F
   BR    R7                  RETURN TO ROUTINE

Notes:

  1. Reassemble UF00 to use the changes made to DFUEX.

  2. Except for segments UF90-UF9Z, if a file ID is used more than once on DBDEF statements, UF00 sends a DB0131 system error and ignores the second file ID.

  3. If a file ID is used twice and the second DBDEF statement is in segment UF90-UF9Z, the second DBDEF statement overrides the first.

It is not necessary to specify data level independence (DLI) with the DBDEF macro. The TPFDF product preserves all data levels holding blocks before a macro or function call. See TPFDF Programming Concepts and Reference for more information about DLI.