EXPFILE: Insert or Remove Files in an Expanded File Chain

#### Search Results

Search

# EXPFILE: Insert or Remove Files in an Expanded File Chain

The EXPFILE function inserts or removes an Adabas file from an expanded file chain.

If an anchor file is removed from the expanded file chain, the next file in the chain becomes the anchor file.

If all files are removed from an expanded file chain, the flags set to indicate that a file is an anchor file are reset. To reestablish a file as an anchor file, assign both the ANCHOR and FILE parameters the file number of the file.

This document covers the following topics.

- Essential Parameters

- Optional Parameters

- Example

## Essential Parameters

> FILE: File to be Inserted or Deleted

>   FILE specifies the number of the Adabas file that should be inserted or removed in the expanded file chain.

> INSERT or REMOVE: Action to Perform

>   Either INSERT or REMOVE must be specified to identify the action that should be performed by the EXPFILE utility function. INSERT will add a file to an expanded file chain; REMOVE will remove a file from an expanded file chain. INSERT and REMOVE are mutually exclusive functions; both of them cannot be specified in the same ADADBS EXPFILE run.

> ANCHOR: File Number of the Anchor File

>   ANCHOR identifies the file number of the anchor file for the expanded file chain.

## Optional Parameters

> NOUSERABEND: Termination without Abend

>   When a parameter error or a functional error occurs while this utility function is running, the utility ordinarily prints an error message and terminates with user abend 34 (with a dump) or user abend 35 (without a dump). If NOUSERABEND is specified, the utility will not abend after printing the error message. Instead, the message "utility TERMINATED DUE TO ERROR CONDITION" is displayed and the utility terminates with condition code 20.

>   Note
>   When NOUSERABEND is specified, we recommend that it be specified as the first parameter of the utility function (before all other parameters). This is necessary to ensure that its parameter error processing occurs properly.

> PASSWORD: File Password

>   PASSWORD specifies the password of the file to be deleted. This parameter is only required if the file is password protected.

> TEST: Test Syntax

>   The TEST parameter tests the operation syntax without actually performing the operation. Only the syntax of the specified parameters can be tested; not the validity of values and variables. See Syntax Checking with the TEST Parameter for more information about using the TEST parameter in ADADBS functions.

## Example

In the following example, file 6 will be added into an expanded file chain and will also become the anchor file for the chain:

    ADADBS EXPFILE FILE=6,INSERT,ANCHOR=6

In the following example, file 7 will be inserted into the expanded file chain that is anchored by file 6:

    ADADBS EXPFILE FILE=7,INSERT,ANCHOR=6

### On this page

- Essential Parameters
- Optional Parameters
- Example