Adabas File

The function generates an Adabas FDT from a Predict file object of type A (Adabas).

Notes:

  1. If Natural Security and Adabas Online Services are installed and function protection for Predict is activated, permission is required to generate an Adabas file.
  2. For UNIX, Windows and OpenVMS users
    With this function you can generate input for the ADAFDU utility to create a new file in your Adabas database. For existing files the FDT and the documentation of the file are compared and the input, necessary to adapt the existing FDT for the utilities ADAINV and ADADBM, is generated. The utilities are started immediately. This method automatically creates a connection between external and documentation object. Before you can delete the documentation object, you must either delete the external object (with the administration function Purge) or disconnect the external and documentation object (with function Disconnect). See also section Handling of External and Documentation Objects in this documentation.
  3. For UNIX, Windows and OpenVMS users
    When using Adabas Version 6.2 or above, it is possible and recommended to generate Adabas files using the Adabas call interface. This simplifies the generation of Adabas files if the Adabas versions of the source and destination differ from each other. In addition, using the Adabas call interface also offers the generation of Adabas files on remote Adabas databases.
  4. An associated LOB file can be specified for a base file containing fields with format LO. A dedicated file object named SAG-ADA-LOB is created during installation. Whenever the number of an associated LOB file is entered in the Adabas attributes of a base file, an own set of Adabas attributes is stored for SAG-ADA-LOB having the specified file number. These settings can be customized. The function Generate Adabas file will automatically create the LOB file in Adabas, when the base file is generated.
  5. Before an existing Adabas file will be updated, the file will be locked for general use with the ADAOPR LOCK utility. After generation (or in case of an abnormal end of a action) the file is unlocked.
  6. When generating Adabas files, the value created for the MUPEX parameter is taken from the default settings made in the Additional Parameters of the Modify ADAWAN/ADACMP Defaults screen.

A file generated with this method is handled like a file created with Adabas Online Services.

This document covers the following topics:


Calling the Function

The Generate Adabas file screen is displayed with function G and code AF in a Predict main menu, or with the command GENERATE FDT.

On mainframes, the following screen is displayed:

13:21:46             *****  P R E D I C T  *****             2007-05-31
Plan   0                  - Generate Adabas file -

Current VM ................ HOME

File ID ..................*
Phys. file number .........
Contained in DA ...........
Phys. database number ..... 36

Load file into database ... Y (Y/N)    Replace if only FDT exists .... N (Y/N)
Update/add fields (FDT) ... N (Y/N)
Update file parameters .... N (Y/N)    Replace if no records loaded .. N (Y/N)
                                       
Change file number ........ N (Y/N)
Format DS/Index ........... Y (Y/N)
Adabas password ...........

List actions .............. Y (Y/N)

Command ===>
Enter-PF1---PF2---PF3---PF4---PF5---PF6---PF7---PF8---PF9---PF10--PF11--PF12---
      Help  Next  Stop  Last  LnkEl Flip  Print Impl  AdmFi SelFi Prof  Main

On Windows and UNIX platforms, the following screen is displayed:

13:28:33             *****  P R E D I C T  *****             2012-01-31
Plan   0                 - Generate Adabas file -

Current VM ................ HOME

File ID ..................*
Phys. file number .........
Contained in DA ...........
Phys. database number .....

Load file into database ... Y (Y/N)    Replace if only FDT exists .... N (Y/N)
Update/add fields (FDT) ... N (Y/N)
Update file parameters .... N (Y/N)    Replace if no records loaded .. N (Y/N)
                                       
Change file number ........ N (Y/N)    Contiguous AC ................. N (Y/N)
Format DS/Index ........... Y (Y/N)    Contiguous DS ................. N (Y/N)
Adabas password ...........            Contiguous NI ................. N (Y/N)
                                       Contiguous UI ................. N (Y/N)
List actions .............. Y (Y/N)    

Command ===>

Parameters

Values for fields which have been locked by your data dictionary administrator cannot be overwritten. These fields are skipped when positioning the cursor with the TAB key. See Generation Defaults.

The following parameters can only be set with the function Defaults > Generation Defaults for object type AF.

Default Parameters
Delay after stop users

Enter a value of up to 99 seconds. This is the time the system waits before actually performing the generation if parameter Stop users using file is set to Y. See below.

Due to Adabas load or too much network traffic, it is possible that not all users have been stopped before the function Generate Adabas file is executed. This delay makes certain that all users really have been stopped before an Adabas file is generated.

Execute online invert
Y If set to N, no online invert function is executed.

Note:
This parameter applies only when generating for Adabas databases of version 7 or above.

Online invert synchronously
Y The online invert function is executed synchronously. The respective Natural session is blocked during the execution but any response code is given on occurence.
N No online invert function is executed synchronously.

Note:
This parameter applies only when generating for Adabas databases of version 7 or above.

Only if TOPISN less than This function is only available if Execute online invert or Online invert synchronously is set to Y.You can specify a value for TOPISN. The default value is 9999999999.

Note:
This parameter applies only when generating for Adabas databases of version 7 or above.

Delay after online invert The online invert function of Adabas version 7 is executed as an asynchronous task. Only one online invert task may be active at a given time. Enter a value of up to 99 seconds. This is the time the system waits after one online invert before performing the next.

Note:
This parameter applies only when generating for Adabas databases of version 7 or above.

Stop users using file
Y All current use of the Adabas file is stopped before a generation run is executed. This parameter must be set to Y on a separate terminal if a file currently used by other users is to be regenerated.
N The function is terminated if other users are accessing the file.

Note:
If Natural Security and Adabas Online Services are installed and function protection for Predict is activated, permission is required to stop users using an Adabas file.

Current VM Adabas files can only be generated from Predict file objects contained in databases accessible from the current virtual machine.
Parameters
File ID, Phys. file number, Contained in DA, Phys. database number The Adabas file definitions can be generated for one specific Adabas file in a database. This file can be identified by the fields File ID, Phys. file number, Database ID or Phys. database number. If parameters do not uniquely identify a file, a selection screen appears.
Load file into database
Y If no file already exists with given file number, a new file is created in the Adabas database.
Update/add fields (FDT)
Y Fields documented in Predict and missing in the FDT are added to the Adabas file. The field length in the FDT is adapted to the value in the Predict object, and fields defined as descriptors in the FDT but not in the Predict documentation are released from descriptor status.
Update file parameters
Y File parameters, including the file space allocation, are adapted to the documentation. If the Adabas file is physically coupled to other files and these relationships are not documented, the files are uncoupled.
Change file number
Y If the Predict file object was renumbered, the Adabas file is renumbered.
Format DS/Index DATA storage is to be physically formatted.
Adabas password Must be provided if the Adabas file (or only an FDT) already exists in the Adabas database and is protected by an Adabas security definition.
List actions
Y Actions which are to be performed to adapt the Adabas file to the Predict specification are listed. Some of the actions may not yet be performed by this generation function: they must be run as batch utilities. The list shows all parameters which are used for generation. Parameters which are invalid or currently not able to be implemented are marked accordingly.
Replace if only FDT exists
Y If a file with this file number once existed in the database and was deleted with the KEEPFDT option, the remaining FDT is overwritten.

Note:
The FDT of the file will not be deleted if the generation terminates abnormally, for example if the field list in Predict contains invalid field definitions.

Replace if no records loaded
Y The Adabas file parameters are replaced, because it is not possible to modify all parameters of an existing file. Replacement is only possible if the Adabas file is empty and is not physically coupled to other Adabas files. The current FDT is kept.
Additional Parameters for UNIX
Adabas version The version of Adabas for which the external object is to be generated (enter an asterisk for valid values or see Adabas Version for more information).
Contiguous AC, DS, NI, UI Setting of space allocations in Adabas utility ADAFDU for Address Converter, Data Storage, Normal Index and Upper Index. See your Adabas Utilities documentation for more information.

Generate Adabas File in Batch Mode

Command: GENERATE FDT

Enter parameters on next line in positional or keyword form. File ID is obligatory, all other parameters are optional.

Field Keyword Position
File ID FILE-ID 1
Phys. file number FNR 2
Database ID DB 3
Phys. database number DBNR 4
Load file into database LOAD 5
Replace if only FDT exists REPLACE-FDT 6
Update/add fields (FDT) UPD-FDT 7
Update file parameters UPD-PARM 8
Replace if no records loaded REPLACE-EMPTY 9
Value exists for compatibilty reasons only REPLACE-CRIT 10
Change file number RENUMBER 11
Format DATA storage DATAFRM 12
Adabas password PSW 13
List actions LIST 14
Stop users using file STOPF 15

If a parameter is not specified, the default value is taken.

Sample Output

File ID ...... GENERATION-EXAMPLE                               PFnr ...   171
Database ID .. DEMO-DB                                          PDBnr ..   180

Action   Parameter                                Remark

DEFFDT   FILE=171
         FNDEF='01,AA'
         Field: GROUP-1
         FNDEF='02,AB,14,U,NU'
         Field: ELE-N-9V5
         FNDEF='02,AC'
         Field: GR-IN-GROUP
         FNDEF='03,AD,4,B,DE,FI'
         Field: ELE-B-4
         FNDEF='03,AE,4,P,NU'
         Field: ELE-PS-5V2
         FNDEF='03,AF,4,B,NU,MU'
         Field: MU-B-4
         FNDEF='02,AG,42,A,NU'
         Field: ELE-A-42
         FNDEF='02,AH,8,G,FI'
         Field: ELE-F-8
         FNDEF='02,AI,3,B,NU'
         Field: ELE-B-3
         FNDEF='01,AL,PE'
         Field: PC-OCC-7
         FNDEF='02,AM,10,U,DE,NU'
         Field: PC-ELE-DE-NS-7V3
         FNDEF='02,AN,4,P,DE,NU,MU'
         Field: PC-MC-PS-6V1
         FNDEF='02,AO'
         Field: PC-GR
         FNDEF='03,AP,2,B,FI'
         Field: PC-ELE-I-2
         FNDEF='03,AQ,14,P,NU'
         Field: PC-PS-20V7
         FNDEF='02,AR,4,G,FI'
         Field: PC-ELE-F-4
         FNDEF='01,AS,4,P,NU'
         Field: ELE-D
         FNDEF='01,AT,7,P,NU'
         Field: ELE-T
         FNDEF='01,AU,1,B,NU'
         Field: ELE-L
         SUBFN='AJ=AG(10,14)'
         Field: SB-ELE-A-5
         SUPDE='S1=AI(1,3),AG(20,36),-'
               'AE(1,4)'
         Field: SP-DE-A-24
         HYPDE='04,S2,4,F,MU,PE=AP,AF'
         Field: HQ-DE-I-4
LOADFILE NOACEXTENSION=NO
         MIXDSDEV=NO
         DATAFRM=YES
         MAXISN=3391
         NAME=GENERATION-EXAMPLE
         MINISN=1
         ASSOPFAC=10
         DATAPFAC=10
         PGMREFRESH=NO
         ISNREUSE=NO
LOADFILE DSREUSE=YES
         MAXDS=0
         MAXNI=0
         MAXUI=0
         CIPHER=NO
         MAXRECL=5060
         UISIZE=41B
         NISIZE=80B
         DSSIZE=233B
         DSDEV=3390