Enter a short description of the task here (optional).
After the DBD import, the data map contains the database segment hierarchical structure with some field definitions. You can now import a copybook for each segment in the IMS database to overlay each segment with its COPYLIB. A copybook for a segment contains the structure of the key data and non-key data and describes the physical layout of the data.
You can import the copybooks for the segments individually or concatenate the copybook files into one file so that you can do a single import for all segments.
Use one of the following methods to open the data map if it is not already open.
Alternatively, you can use a PL/I copybook for an IMS source.
Verify that the column numbers in the
Start
and
End
fields define the copybook column range.
The following image shows an example of a completed dialog box:
Click
Next
.
If you selected
Local
in step 3a, the
Import Copybook - Local Cobol Details
dialog box appears:
If you selected
Remote
in step 3a, the
Import Copybook - Remote Cobol Details
dialog box appears:
Complete the following information:
In the
File Name
field, enter the fully qualified name of the copybook file to be imported.
If you selected the
Remote
option, complete the following additional fields to connect to the remote z/OS system from which to read the copybook:
In the
Location
list, select the z/OS node name.
In the
User ID
and
Password
fields, if you set the first parameter in the SECURITY statement to 1 or 2 in the DBMOVER configuration member on the z/OS system, enter a valid user ID and password that allows access to the z/OS system.
Optionally, edit the default DBD name in the
Save File Locally As
field to save the copybook locally under another name. Use .cob as the file name extension.
Click
Preview
to verify the name of copybook to be imported and to preview its contents. When you are finished, close the preview window.
Click
Next
.
The
Import Copybook - Configuration Details
dialog box appears again:
Optionally, edit one or more of the options.
Ensure that the
Refresh table columns for imported records
check box is selected to eliminate the need to perform additional steps later to refresh table definitions with the additional columns from the copybook.
If the DBD and COBOL copybook use the same record (segment) names, replace the DBD record information with the copybook information for the same record (segment). In the
Record Browse
list, select a record name. Then verify that it matches the
Name
value.
The
Duplicate Record Definition
dialog box appears:
If this dialog box is not displayed, start over. When you return to the
Record Definition
dialog box, ensure that the
Record Browse
and
Name
values match.
You can edit the copybook to use the same record name as the DBD or change the record names during the copybook import operation.
Select
Overwrite
and select
Fields Only
in the adjacent list box.
Click
OK
.
If the copybook contains REDEFINES clauses, the
Copybook Redefines
window indicates that REDEFINES clauses exist.
Repeat Steps 10-13 for each imported record
After the information for the last record is imported, the
Cobol Import
window displays the copybook and Copybook Message Log:
Review the Copybook Message Log to determine if errors occurred.
The log also lists the number of records and fields that were imported. The log displays 0 for the number of tables if the copybook import did not refresh the table definitions. This situation occurs if you did not select the
Refresh table columns for imported records
check box on the
Import Copybook - Configuration Details
dialog box.
Close the
Cobol Import
window.
At this point, the data map includes the hierarchical structure of the database from the DBD import and the record definitions with the updated field definitions from the COBOL copybook import.