Main logic
At the start, the exit establishes addressability to the
VSAM record area and the DB2® record
area. The only data in the DB2 record
area is the key of the record.
Test for the call type being processed
Once the appropriate DB2 table
working storage record has been built, there is a test for the type
of call being processed.
Error handling
If an SQL error occurs, an error message is issued.
Build a load record
The IRDFUNCT parameter is L when the VIDLOAD utility is
running.
General notes for MULTIRD
MULTIRD builds DB2 column
values prior to issuing an SQL call or building a load record. No
field level reengineering needs to be performed so the DB2 column values are built by MOVE statements.
Running VIDLOAD
The first time MULTIRD is tested is when you run VIDLOAD.
Because multiple output records are written for each VSAM record,
you must specify the DD statement LOADOUTM in the VIDLOAD JCL.
Loading the DB2 data
The output file your.APPLCTL.LOADDB2
from the VIDLOAD utility is loaded into DB2.
Because APPLCTL is converted to multiple tables, the records in this
file are for multiple tables in DB2.
Loading large tables
The
DB2
load utility
reads every record in the input sequential data set to satisfy the
WHEN statement. If you are migrating a very large VSAM file, it is
often more efficient to split the VIDLOAD output file into a separate
data set for each table.