ENFORM User's Guide

Interface Procedures
Host Language Interface
058058 Tandem Computers Incorporated 6–11
ENFORMFINISH Procedure ENFORMFINISH is called once to terminate the interface to ENFORM. The syntax of
the ENFORMFINISH procedure is:
COBOL:
ENTER ENFORMFINISH USING (
ctlblock
)
FORTRAN:
CALL ENFORMFINISH (
ctlblock
)
TAL:
CALL ENFORMFINISH (
ctlblock
)
ctlblock
INT:ref, is the same 18-word integer array control block that was supplied to
ENFORMSTART for global storage among all ENFORM procedure calls. The host
language program must not change the control block between calls to ENFORM.
Examples In the first example, a list of all the employees in a given region is required. A query
containing one FIND statement is compiled. The query passes the required records to
a COBOL program.
Before the COBOL program can execute, a description of the records being passed
must be added to the data dictionary and the file containing the FIND statement must
be compiled.
The record description of the record being passed is defined in the data dictionary as
shown in Figure 6-2. The record description contains a field for the region number
(regnum), the branch number (branchnum), and the employee name (empname). For
complete instructions about dictionary definition, refer to the Data Definition Language
(DDL) Reference Manual.
Figure 6-2. DDL Description of Record Passed to COBOL Program
Record findfil.
file is "findfil".
02 regnum
type *. 02 branchnum
type *. 02 empname
type*.
type*.
pic x(18).
end