bdfg1m0gGeneral Information

TPFDF File Types

There are three types of physical files in TPFDF:

Fixed Files

The database administrator defines each fixed file as consisting of a fixed number of blocks on a specific part of DASD. When a fixed file has been allocated, it contains only prime blocks, so it contains exactly as many blocks as there are subfiles in the file.

When an application program adds LRECs to a subfile in a fixed file, the prime block may become full. When this happens, TPFDF obtains a free pool block and creates a chain from this to the fixed prime block that overflowed.

Fixed files are suitable when the number of subfiles is known in advance and it is unlikely that many LRECs will overflow into pool blocks.

Miscellaneous Files

A miscellaneous file is a type of fixed file. The database administrator normally defines some miscellaneous fixed files on DASD with record types #MISCS, #MISCL, and #MISC4. The last character in the name identifies the size used for prime blocks in the subfile.

Use miscellaneous files for small amounts of data that require a fixed file.

Pool Files

Pool files consist of pool blocks that are used as prime blocks and overflow blocks in a file. Pool blocks can be short-term or long-term. Short-term pool blocks are likely to be reused by a TPF system or ALCS environment in seconds or minutes. Long-term pool blocks have an indefinite lifetime.

Many TPFDF macros, functions, commands, and indexing support use long-term pool files. To use long-term pool files for permanent storage, save the file address of each prime block in a fixed file. You cannot use short-term pool files for permanent storage.