ENFORM User's Guide
Using an ENFORM Server
ENFORM Servers
7–16 058058 Tandem Computers Incorporated
It might be necessary for the query processor to read a file more than once; for
example, to process a LINK statement or when a NonStop query processor restarts a
query. In this case, the ENFORM server must be able to send the query processor the
first record, more than once, at any point during a series of request messages.
An ENFORM server session consists of one query execution or the period of time
an ENFORM server is held open by an active server query processor. An
ENFORM server can be opened by multiple query processors at the same time.
The ENFORM server can be designated as a file to be held open by the server
query processor when the query processor is started.
An ENFORM server can wait for a request without being opened by the query
processor (requester).
The message header is reinitialized and verified on every request and reply. The
message data record area is not modified. The query processor initializes the
control block to all zeros only on the first input request.
If an ENFORM server returns an exception condition, or ENFORM encounters an
exception condition while trying to communicate with an ENFORM server, the
query processor attempts to CLOSE the ENFORM server.
If a primary process failure occurs causing a server query processor to restart a
query, the query begins by requesting the first record in the file. This operation is
transparent to the ENFORM server, since an ENFORM server must be able to
repeatedly supply records in a sequential manner.
If an ASSIGN command is used to specify an exclusion mode for an ENFORM
server, that exclusion mode is included in the OPEN message flags word
sysmsg[1]>. Otherwise, the Query Processor provides the SHARED (0) exclusion
mode. (For more information, refer to the GUARDIAN Operating System
Programmer’s Guide.)
Using an ENFORM
Server
This section describes some general restrictions and performance considerations
involved in using ENFORM servers.
Restrictions Related to
Using ENFORM Servers
The following restrictions apply to the interaction of an ENFORM server with the
query processor:
1. The ENFORM server must be running before the query processor issues an OPEN
message. After receiving a Command Interpreter startup message, an ENFORM
Server can be opened by the query processor. It is your responsibility to start the
ENFORM server before executing the ENFORM query that will use the server.
2. Document the order, in which the records are presented to the query processor, in
the SEQUENCE IS clause of the related DDL description. This can prevent the
query processor from having to read the ENFORM server file many times or
perform an unnecessary sort operation.