File

#### Search Results

Search

# File

This document covers the following topics:

- File Maintenance

- File Retrieval

- File Active Retrieval

- Administration Implemented File

## File Maintenance

The File Maintenance Menu is called with the command `MAINTAIN FILE`.

### Overview of File Maintenance Functions and Commands

Function | Code | Command
--- | --- | ---
Add a file | A | ADD FILE
Copy file | C | COPY FILE
Display file | D | DISPLAY FILE
Modify file | M | MODIFY FILE
Rename/Renumber file | N | RENAME FILE
Purge file | P | PURGE FILE
Edit description of a file | W | EDIT FILE DESCRIPTION
Edit elements of a file (see Note:) | E | EDIT FILE ELEMENT
Push backward | B | PUSH FILE
Link children | L | LINK FILE <active-association-type>
Edit owners of a file | O | EDIT FILE OWNER
Select file from a list | S | SELECT FILE
Modify Adabas attributes | J | MODIFY ADA-ATTR
Force standard | F | FORCE FILE
Modify Vista elements | K | MODIFY VISTA-FI
Edit Subquery of a File | Y | EDIT FILE SUBQUERY

Note
The function Edit elements of a file does not appear on the File Maintenance Menu, but can still be called with function code E.

The command `FORCE FILE` is one of the few maintenance commands that can be executed in batch mode.

### File Maintenance Parameters

Keyword | Field | Position
--- | --- | ---
ID | File ID | 1
<> | Copy ID | 2

### File-Specific Maintenance Commands

Note
See also Standard Maintenance Commands .

Command | Description
--- | ---
RENAME FILE<file-ID> | This command is used to modify the following file attributes in one transaction: file ID file number file type master file logical distribution type Adabas SQL usage Note These values cannot be changed with the Modify Database function.
PUSH FILE<file-ID><copy-file-ID> | The field definitions of the specified file are copied into the standard file according to the following rules: If the field is already present in the standard file and a link exists between the specified file and the standard file, no action is taken If the field is already present in the standard file but no link exists, a link is established. If the field is not found in the standard file, it is copied and a link is established. The standard file is specified in the field Copy file ID. The coupling of field definitions on different levels to ensure consistent data definitions is described in the section Rippling under File of the Predefined Object Types in Predict documentation.
FORCE FILE<file-ID> | Compares the coupled attributes of all fields defined in the specified standard file with the attributes of the coupled fields in other files. If attributes of coupled fields are different (and these fields are not marked as non-standard), change them to match the standard file.
MODIFY ADA-ATTR <file-ID> | Modifies the physical Adabas attributes of Adabas files.
MODIFY VISTA-FI <file-ID> | Modifies Vista attributes.
EDIT FILE SUBQUERY <file-ID> | Invokes the Subquery Editor, a modified Natural Editor which is used to edit the following: Subquery clause of SQL view Derived field expression
EDIT FILE ELEMENT <file-ID> | Reads the field list of the specified file into the source area and activates the full screen editor which supports many edit and line commands.

## File Retrieval

The File Retrieval Menu is called with RETRIEVE FILE.

### Overview of File Retrieval Functions and Commands

Retrieval Type | Code | Default Output Mode | Command
--- | --- | --- | ---
Files | D | D | DISPLAY FILE
L | LIST FILE
S | SELECT FILE
D | SHOW FILE
Execute retrieval models | E | T | EXECMODEL FILE
Dummy/Placeholder files | C | L | DUMMY FILE <passive-association-type>
Difference of files | A |  | DIFFERENCE FILE
Files with parents | B | D | PARENTS FILE <passive-association-type>
Files with no parent | O | L | FREE FILE ANY | ALL | <passive-association-type>
Files with children | T | D | CHILDREN FILE <active-association-type>
Files with no child | U | L | EMPTY FILE ANY | ALL | <active-association-type>
Files related to a file | R | L | RELATED FILE

### File Retrieval Parameters

Keyword | Field | Position
--- | --- | ---
ID | File ID | 1
PARENT | Contained in DA | 2
EXTERNAL | External name | 3
RES | Restrictions | 4
OUT | Output options | 5
TYPE | Files of type | 6
FNR | File number | 7
MODEL | Model | 8
MODE | Output mode | 9

### File-Specific Retrieval Commands

See also Standard Retrieval Commands.

Command | Description
--- | ---
DIFFERENCE FILE | Compares files and displays the differences. The file attributes, the fields and the field attributes can be compared. The fields are compared using the field ID. If a userview is compared with its master file, however, the fields are compared by two-character Short name. The userview is always taken as first file, irrespective of which file is entered under FIRST-FILE. See the section File in the Predefined Object Types in Predict documentation for more information.
Using DIFFERENCE FILE in Batch Mode | The parameters FIRST-FILE, SECOND-FILE, LIST and FILE-ATTR are mandatory. Each field attribute to be compared must be specified.
Keyword | Field | Position
FIRST-FILE; | First file ID | 1
SECOND-FILE; | Second file ID | 2
LIST | List fields | 3
FILE-ATTR | Compare file attributes | 4
ORDER; | the order | 5
EXISTENCE | the existence | 6
COMMENT | abstract | 7
OW; | owner IDs | 8
KEY | keywords | 9
DESC | description | 10
SYNONYM | field name synonyms | 11
STANDARD | standard file | 12
VERIFICATION | verification | 13
ADABAS-SEC | Adabas attributes | 14
FIELD-DEF | field definition | 15
NATURAL | Natural attributes | 16
3GL-SPECIF | specification for 3GL | 17
VSAM | VSAM attributes | 18
Example: Compare file PDA-7 with file PDA-13 and report the differences of the field's Adabas and Natural attributes:
    DIFFERENCE FILE

       PDA-7,PDA-13,LIST=D,N,ADABAS-SEC=X,,X
Note For the field attributes to be compared, the corresponding keyword must be specified in the statement DIFFERENCE FILE, but the value assigned to the keyword is of no importance in this case. If a field attribute is not to be compared, the corresponding keyword must be omitted.
RELATED FILE<file-ID> | Lists the following types of objects: master files with their userviews userviews with their master files other userviews of these master files For physical VSAM files the related logical VSAM files are also listed; for IMS segments the IMS segment layouts are also listed.

## File Active Retrieval

The File Active Retrieval Menu is called with `ACTIVE FILE`.

### Overview of File Active Retrieval Functions and Commands

Retrieval Type | Code | Default Output Mode | Command
--- | --- | --- | ---
Files |  |  | see File Retrieval
Files ref. by members | R | L | REFERENCED FILE
| C | COUNT FILE
Files inconsistently used | U | L | UNUSED FILE
Files not documented | O | L | UNDEFINED FILE
Files accessed via dyn. SQL | V | L | DYNAMIC FILE

### File Active Retrieval Parameters

Keyword | Field | Position
--- | --- | ---
ID | File ID | 1
PARENT | Contained in DA | 2
RES | Restrictions | 3
OUT | Output options | 4
TYPE | Files of type | 5
FNR | File number | 6
USE | Usage | 7
MASTER | For master files | 8
SET | Save set | 9
MODE | Output mode | not applicable

### File-Specific Active Retrieval Commands

Command | Description
--- | ---
REFERENCED FILE | Lists for every referenced file all members using the file.
COUNT FILE | Shows for every referenced file a summary list which indicates for each library how many members use the file and the file usage, for example read or update. If members of more than one library use the file, the total usages are also given.
UNUSED FILE | Lists files that are not used by any member or which may be used incorrectly. Example: a file that is never updated or never read. If the parameter Usage is specified, only those files which are not used in this manner are shown.
UNDEFINED FILE | Lists files that are referenced by members but are not documented in Predict and have no DDM.
DYNAMIC FILE | Lists DB2 tables and views (file types D or E) that are used by Natural members but not via static SQL.

## Administration Implemented File

The Administration Implemented File menu is called with ADMINISTRATE FILE.

### Overview of File Administration Functions and Commands

Function | Code | Command
--- | --- | ---
Disconnect implementation | C | DISCONNECT FDT
DISCONNECT DDM
DISCONNECT NDB
DISCONNECT TABLE
DISCONNECT ESQ
DISCONNECT SN-FILE
DISCONNECT NSC-FILE
Display implementation | D | DISPLAY ADACMP
DISPLAY ADAINV
DISPLAY ADASCR
DISPLAY ADAVSAM
DISPLAY BAL
DISPLAY COBOL
DISPLAY DDM
DISPLAY ESQ
DISPLAY FDT
DISPLAY FORTRAN
DISPLAY LANG-C
DISPLAY PLI
DISPLAY RULE
DISPLAY TABLE
Rename implementation | N | RENAME ADACMP
RENAME ADAINV
RENAME ADASCR
RENAME ADAVSAM
RENAME BAL
RENAME COBOL
RENAME FORTRAN
RENAME LANG-C
RENAME PLI
RENAME TABLE
Purge implementation | P | PURGE ADACMP
PURGE ADAINV
PURGE ADASCR
PURGE ADAVSAM
PURGE BAL
PURGE COBOL
PURGE ESQ
PURGE FDT
PURGE FORTRAN
PURGE LANG-C
PURGE NDB
PURGE NSC-FILE
PURGE PLI
PURGE SN-FILE
PURGE TABLE
Refresh file | R | REFRESH FDT
REFRESH TABLE
Select implementation | S | SELECT ADACMP
SELECT ADAINV
SELECT ADASCR
SELECT ADAVSAM
SELECT BAL
SELECT COBOL
SELECT DDM
SELECT ESQ
SELECT FDT
SELECT FORTRAN
SELECT LANG-C
SELECT NDB
SELECT NSC-FILE
SELECT PLI
SELECT RULE
SELECT SN-FILE
SELECT TABLE

### File Administration Parameters

Keyword | Field | Position
--- | --- | ---
ID | File ID | 1
PARENT | Contained in DA | 2
EXTERNAL | External name | 3
MEM | Member | 4
LIB | Library | 5
MODIFIED | Only modified | 6
RES | Restrictions | 7
TYPE | Files of type | 8
FNR | File number | 9
PFNR | Phys Fnr | 10
PDBNR | Phys DBnr | 11

### File-specific Administration Commands

See Standard Administration Commands.

Command | Description
--- | ---
REFRESH FILE | Deletes all records stored in Adabas files or DB2 tables/views. The data structure remains intact.
PURGE VISTATAB | Deletes entries in Vista translation tables. This function cannot be executed in batch mode.

### On this page

- File Maintenance
- File Retrieval
- File Active Retrieval
- Administration Implemented File