In addition to the re-engineering capabilities that
CICS®
VT invokes automatically, two APIs
are provided for more complicated restructuring. For example, assume
that
you have multiple copybooks for the same file and apart from the key,
the
copybook attributes are completely different. Also assume that your users
want the file separated into multiple
DB2®
tables, according to the copybook type.
This
DB2
implementation
is possible using a combination of two types of
CICS
VT user exits. These are:
-
A
field level exit to perform re-engineering of one or more fields. This
is
known as a field build exit (FBE).
-
A record level exit that performs
re-engineering of an entire record. This exit is triggered by a call that
inserts a new record, replaces an existing record, or deletes an existing
record. This is known as an insert, replace, delete (IRD) exit.
In the current example where an existing file needs to be split into
separate
DB2
tables,
these exits would operate as follows:
- FBE
- This exit would decide which table contains the required
records, by
analyzing a specific field or key value in the record. It contains the
necessary
SQL to process retrieval calls.
- IRD
- This exit would handle update calls, and contains the necessary SQL
to update the
DB2
tables.
The coding of user exits is described in the manual
CICS
VT
Data Reengineering and Customisation Guide
.
