Access Files for Adabas

In this section:

An Access File describes the physical attributes of the Adabas file, such as the database number, file number, descriptors, and security. See Overview of Master and Access Files for more information about Master and Access Files.

Access Files store database access information used to translate report requests into the required Adabas direct calls.

In the z/OS environment, the Access File is located in a PDS allocated to the DDNAME ACCESS. Each member is a separate Access File.

An Access File consists of 80-character records in comma-delimited format. A record in an Access File contains a list of attributes and values, separated by commas and terminated with a comma and dollar sign (,$). This list is free-form and spans several lines if necessary. You can specify attributes in any order.

The server reads blank lines, and lines starting with a dollar sign in column one, as comments.

Every Access File contains a release declaration and at least one segment declaration. Release declarations and segment declarations each have their own set of attributes. These attributes are discussed in the following topics.

The following is a sample Access File:

$$$ FILENAME=EMPFILE1,SUFFIX=ADBSINX,$
RELEASE=6,OPEN=YES,$
 
$ ADABAS FILE = EMPLOYEES                         DICTIONARY =
SEGNAM=S01   ,ACCESS=ADBS,FILENO=001,DBNO=1,CALLTYPE=RL,
              SEQFIELD=PERSONNEL_ID,$
FIELD=DEPT_PERSON                         ,TYPE=SPR,$
FIELD=DEPT                                ,TYPE=DSC,NU=YES,$
FIELD=NAME                                ,TYPE=   ,NU=NO,$
 FIELD=LEAVE_LEFT                         ,TYPE=SPR,$
 FIELD=LEAVE_DUE                          ,TYPE=   ,NU=YES,$
 FIELD=LEAVE_TAKEN                        ,TYPE=   ,NU=YES,$
FIELD=DEPARTMENT                          ,TYPE=NOP,NU=NO,$
SEGNAM=AI0101,ACCESS=MU  ,FILENO=001,$ ADDRESS_LINE
SEGNAM=AQ0201,ACCESS=PE  ,FILENO=001,DBNO=1,$ INCOME
SEGNAM=AT0301,ACCESS=MU  ,FILENO=001,DBNO=1,$ BONUS
SEGNAM=AW0401,ACCESS=PE  ,FILENO=001,$ LEAVE_BOOKED
SEGNAM=AZ0501,ACCESS=MU  ,FILENO=001,$ LANG

Top of page

x
Release Declaration

In this section:

The release declaration must be the first uncommented line of the Access File. It identifies the release of Adabas and indicates whether the Adapter for Adabas issues Adabas OPEN and CLOSE calls for each report request.

The syntax is

RELEASE=relnum [,OPEN={YES|NO}] ,$

where:

relnum

Is the Adabas release number.

OPEN

Specifies whether the adapter issues Adabas OPEN and CLOSE calls to Adabas in each report request. Possible values are:

YES which indicates that Adabas OPEN and CLOSE calls are issued. YES is the default value.

NO which indicates that Adabas OPEN and CLOSE calls are not issued.



x
RELEASE

The first declaration in the Access File contains the Adabas release number with the attribute RELEASE. Specify the full release number. The value is for documentation only.

The following example illustrates the use of the RELEASE attribute to specify the Adabas release number:

RELEASE=6 ,$


x
OPEN

The OPEN attribute specifies whether the Adapter for Adabas issues Adabas OPEN and CLOSE calls to Adabas in each report request. Specifying YES or NO achieves the following results:

Value

Result

YES

The adapter issues an OPEN call to Adabas at the start of a call set initiated by a retrieval request. An Adabas CLOSE is issued at the end of retrieval for the request. YES is the default value.

RELEASE=6 , OPEN=YES ,$
NO

Adabas OPEN and CLOSE calls are not issued for any retrieval request.

RELEASE=4.1, OPEN=NO ,$

Accept the default value (YES) unless you are using an Adabas release lower than 5.0.

Note: To reduce overhead incurred in opening and closing databases when processing requests from multiple agents, the Adapter for Adabas allows opened databases to remain open until one of the following actions occurs:

  • A request changes the database, the file, the database mode (close) or its access mode (read/write).
  • The last agent disconnects.
  • The last open database is closed explicitly.



x
Segment Attributes in Access Files

In this section:

Segment declarations contain detailed information about each segment of an Adabas file. The segment declaration attributes specify the segment name, the file and database numbers, and the Adabas password, as well as retrieval options.

The syntax is

SEGNAM=segname, ACCESS=access, FILENO=file_number [,DBNO=database_number]
[,CALLTYPE={FIND|RL}] [,USE={FIND|ANY}] [,SEQFIELD=seqfield] [,PASS=password]
[,FETCH={ON|OFF}] [,FETCHSIZE={n|MAX}] [,UNQKEYNAME=unique_field] [,WRITE=YES|NO],$

where:

segname

Is the SEGNAME value from the Master File.

access

Specifies the segment type that the adapter uses for each segment. Possible values are:

ADBS which is for a segment that contains only non-repeating fields. ADBS is the default value.

PE which is for a segment that is a periodic group in the same file as the parent segment.

MU which is for a segment that is a multi-value field in the same file as the parent segment.

file_number

Is the number that identifies an Adabas file.

database_number

Is the number that identifies an Adabas database.

CALLTYPE

Indicates the type of data retrieval call constructed by the adapter. Possible values are:

FIND in which a FIND call is issued when there are one or more WHERE or IF statements in a retrieval request detected against fields defined with INDEX=I. FIND is the default value.

RL in which a Read Logical (RL) call is issued when there are one or more WHERE or IF statements against fields defined with INDEX=I.

Note: See your database administrator for the most efficient CALLTYPE to be used at your site.

USE

Indicates a method for handling unreadable sub or superdescriptor fields that are derived from PE or MU access types and defined in the root segment. Possible values are:

FIND indicates that the S1 command will be issued against such a field even if CALLTYPE is RL.

ANY indicates that fields are not of the sub/superdescriptor types. ANY, or the absence of a USE= entry, are the default values.

seqfield

Provides a default index which controls Read Logical (RL) retrieval when there is no IF or WHERE selection test.

password

Is the Adabas password for the file.

FETCH

Indicates whether to use the Fetch feature. Possible values are:

ON which sets the Fetch feature on for the user session. ON is the default value.

OFF which sets the Fetch feature off for the user session.

If you include this attribute, you must also include FETCHSIZE (see below).

FETCHSIZE

Sets the number of records per buffer. Possible values are:

n which is the number of records per buffer (1 to 32K). 10 is the default value.

MAX which is automatically calculated by the adapter to allow the maximum number of records that fit in a 32K buffer.

UNQKEYNAME

Is the attribute that indicates the unique key. It does not necessarily define the key described in the ADABAS FDT with the UQ option.

WRITE

Is the attribute that indicates the WRITE capability. NO is the default value.

Note: FETCH and FETCHSIZE are applicable only to segments described as ACCESS=ADBS. FETCH and FETCHSIZE can be set dynamically to override the Access File settings.

Special attributes that apply to embedded JOINs are explained in Implementing Embedded JOINs: KEYFLD and IXFLD. Attributes that apply to superdescriptors and subdescriptors are explained in Customizing the Adabas Environment.



x
SEGNAM

The SEGNAM attribute specifies the name of the segment being described. It is the same name as the SEGMENT value in the Master File.



x
ACCESS

The ACCESS attribute specifies the segment type that the Adapter for Adabas uses for each segment. The values are:

All three access values use the attributes FILENO and DBNO, as shown in this partial Access File for EMPLOYEES with the specification of PE and MU fields.

$$$ FILENAME=EMPFILE1,SUFFIX=ADBSINX,$
RELEASE=6,OPEN=YES,$
 
$ ADABAS FILE = EMPLOYEES                         DICTIONARY =
SEGNAM=S01   ,ACCESS=ADBS,FILENO=001,DBNO=1,CALLTYPE=RL,
              SEQFIELD=PERSONNEL_ID,$
SEGNAM=AQ0201,ACCESS=PE  ,FILENO=001,DBNO=1,$ INCOME
SEGNAM=AT0301,ACCESS=MU  ,FILENO=001,DBNO=1,$ BONUS
SEGNAM=AW0401,ACCESS=PE  ,FILENO=001,DBNO=1,$ LEAVE_BOOKED


x
ACCESS=ADBS

ACCESS=ADBS specifies the main segment of the file. This segment contains only non-repeating fields.



x
FILENO

The FILENO attribute specifies the Adabas file number. You need this file number to identify the Adabas file(s) you wish to access. The valid values are 1 to 255 (5000 is the maximum value for a mainframe platform). The FILENO attribute has to be defined for segments with ACCESS=ADBS. If the FILENO attribute is omitted for segments with ACCESS=MU/PE, then it will be taken from the corresponding parent segment.

Suppose you are accessing two segments: the first is in the EMPLOYEE file, and the second is in the INSURANCE file. To describe this situation in the Access File, use the SEGNAM and FILENO attributes as illustrated in DBNO.



x
DBNO

The DBNO attribute specifies the Adabas database number. It is used when you define files from multiple databases in one Master File. If it is not provided, the DBNO will be read from the DDCARD (on a mainframe platform only). If the DDCARD is not allocated, the adapter uses the default value, DBNO=0.

If the DBNO attribute is omitted for a segment with ACCESS=PE/MU, it will be taken from the corresponding parent segment. The DBNO attribute has to be defined for segments with ACCESS=ADBS on non-mainframe platforms.

The following example illustrates the use of both the FILENO and DBNO attributes to account for the files being in different databases:

SEGNAM=ONE   ,FILENO=1  ,DBNO=1 ,... ,$
SEGNAM=PAY   ,FILENO=2  ,DBNO=3 ,... ,$


x
CALLTYPE

The CALLTYPE attribute affects how the Adapter for Adabas processes WHERE and IF statements on descriptors in report requests and how it retrieves cross-referenced file data from a descendant segment. With CALLTYPE, you optionally specify the type of access to use in order to process the inverted lists for any given segment. Ask your Adabas database administrator to advise you when you are selecting a CALLTYPE.

The possible values are:

FIND

An Adabas FIND call is issued when there are one or more WHERE or IF statements against fields defined to the server with INDEX=I. The search is on specific values of the field.

The Adapter for Adabas can generate Adabas FIND (S1) calls even when non-descriptor fields are used as search criteria. This can occur whenever CALLTYPE=FIND is specified in the Access File, and if you include an IF or WHERE test when referencing a non-descriptor field in your TABLE or TABLEF request.

To turn off this feature, see the topic in Adapter Navigation that discusses the optimization of the FIND call using non-descriptor fields.

RL

An Adabas Read Logical call is issued when there are one or more WHERE or IF statements against fields defined to the server with INDEX=I.

Note: If you have selected a field defined with TYPE=NOP (for example, subdescriptors), a FIND call is issued even if RL has been specified in cases when:

  • SET NOPACCESS FIND was performed.
  • The server is running in OpenVMS environment.
  • The same Adabas field is defined in the descendant PE/MU segment.

Switching from RL to FIND mode is also performed if a field is defined:

  • With TYPE=SPR and the server is running in an OpenVMS environment.
  • With TYPE=PDS (phonetic descriptor) or TYPE=HDS (hyperdescriptor).
  • In a PE segment (is a part of periodic group).

The adapter uses Read Logical by ISN (L1) calls to retrieve all records for the entry segment when the:

  • Report request does not contain an optimizable selection test on an inverted list or an ISN list.
  • The Access File contains a SEQFIELD value for that segment and this value is equal to the ISN field name.

Adabas returns each record corresponding to an entry in the Address Converter. The records are in ascending value of the ISN.

The first IF statement in a request that refers to a field with INDEX=I determines the inverted list used for the Read Logical access for the root of the subtree.

When retrieving descendant segments, the Adapter for Adabas issues a Read Logical call using the descriptor pointed to by IXFLD. For more information on IXFLD, refer to Implementing Embedded JOINs: KEYFLD and IXFLD.

For CALLTYPE=RL, all other selection tests on descriptor fields specified in your report request are applied after the record is returned.



x
USE=FIND

The Adapter for Adabas cannot read sub/superdescriptors that are derived from PE/MU access types and defined in a root segment. These types of fields may be used only in an Adabas FIND command that produces a "trusted" answer set. However, you can add the description parameter USE=FIND in the Access File for sub and superdescriptor fields that cannot be read by the adapter.

The following processing rules apply for fields that are defined with this description or that are automatically recognized as a fields derived from PE/MU:

The Create Synonym facility always places sub/superdescriptors derived from PE/MU in a root segment with TYPE=NOP in the Access File. Moreover, the sub descriptors have the description USE=UFIND in the Access File.



x
SEQFIELD

The SEQFIELD attribute specifies the field you want to use as the sequencing value:

RELEASE=6,OPEN=YES,$
 
$ ADABAS FILE = EMPLOYEES                         DICTIONARY =
SEGNAM=S01,ACCESS=ADBS,FILENO=001,DBNO=1,CALLTYPE=RL,
           SEQFIELD=PERSONNEL_ID,$


x
PASS

The PASS attribute specifies the Adabas password for the file. It is required if the file is password protected.

You must specify the password for each password-protected file you use. For example:

SEGNAM=ONE   ,FILENO=1   ,DBNO=1   ,PASS=ONEXX ,...,$
SEGNAM=PAY   ,FILENO=2   ,DBNO=3   ,PASS=USER2 ,...,$


x
FETCH

The FETCH attribute indicates whether to use the Fetch feature for segments described as ACCESS=ADBS in the Access File. Valid values are ON (default) or OFF.



x
FETCHSIZE

The FETCHSIZE attribute sets the number of records per buffer. You can supply a specific number or have the Adapter for Adabas automatically calculate the maximum number of records that fit in a 32K buffer.

The following is an example of an Access File that enables the Fetch feature and sets the number of records per buffer to 15.

$$$ FILENAME=EMPFILE1,SUFFIX=ADBSINX,$
RELEASE=6,OPEN=YES,$
 
$ ADABAS FILE = EMPLOYEES                         DICTIONARY =
SEGNAM=S01,ACCESS=ADBS,FILENO=001,CALLTYPE=RL,
           SEQFIELD=PERSONNEL_ID,FETCH=ON,FETCHSIZE=15,$

WebFOCUS