Primary Key References; Figure 3-2. Records With Duplicate Field Names - Tandem ENFORM 058057 Reference Manual

Data management library
Table of Contents

Advertisement

A field name requires as much qualifying as necessary to uniquely identify the field to
ENFORM. The necessary qualification might be as simple as combining the field
name with the record name or group name. It might require combining the field name
with both a group name and a record name or with two group names. Consider the
record descriptions shown in Figure 3-2.

Figure 3-2. Records with Duplicate Field Names

If both the stock-items and shelf-items record descriptions are open, ink must be
qualified. To qualify ink within shelf-items, one of the following must be entered:

Primary Key References

The records in data base files can be uniquely identified by the value of a primary key.
For data base files with key-sequenced file structure, the primary key is part of the
record. For data base files with relative, unstructured, or entry-sequenced file
structure, the primary key is not part of the record. Primary keys can be referenced in
two forms:
The form record-name.KEY can appear for only one relative, entry-sequenced, or
unstructured file per query.
058057 Tandem Computers Incorporated
RECORD stock-items.
FILE IS "stock"
KEY-SEQUENCED.
02 depot-num
PIC 99.
02 cont-num
PIC 99.
02 erasers.
05 ink
PIC 99.
05 gum
PIC 99.
05 pink
PIC 99.
02 ink-pens.
05 felt-tip PIC 99.
05 b-point
PIC 99.
05 fountain PIC 99.
ink OF erasers OF shelf-items
shelf-items.erasers.ink
KEY OF record-name
or
record-name .KEY
ENFORM Language Elements
Rules for Naming User Defined Elements
RECORD shelf-items.
FILE is "shelf" KEY-SEQUENCED.
02 dept-num
PIC 99.
02 dept-name
PIC X(10).
02 cont-num
PIC 99.
02 pens.
05 b-point
PIC 99.
05 felt-tip
PIC 99.
02 erasers.
05 ink
PIC 99.
05 gum
PIC 99.
05 gray
PIC 99.
3–7

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Enform

Table of Contents