CONNX for IMS fully supports the IBM® IMS™ Library Integrity Utilities for z/OS. The use of these utilities allows CONNX to automatically extract parent/child relationships between segments, key information and metadata. If the IMS Library Integrity Utilities are not available on a system, CONNX provides a mechanism to provide the necessary information via the combination of a COBOL Copybook and an Index Text Specification file.
The Index Text Specification file should be a Windows comma separated text file with a .txt extension. The format of each line of this file is as follows:
One import text file may contain records for multiple PSBs. Only the PSB specified on the Import dialog will be displayed when importing.
Syntax |
Description |
---|---|
<PSBNAME> |
Name of the PSB. |
<PCBNAME> |
Name of the PCB. |
<DBDNAME> |
Name of the DBD. |
<SEGMENTNAME> |
Name of the Segment. |
<PARENTSEGMENTNAME> |
Name of this segment's parent. If the segment does not have a parent, this field must be blank. |
<KEYNAME> |
Name of the key field for this segment. |
<KEYDATATYPE> |
The data type of this segments key field. Possible values are P, C, F and H. Please see the conversion table below for a definition of these types. |
<KEYOFFSET> |
The starting position of the key field in the segment. This is a 0 based value - the first position is offset 0. |
<KEYLENGTH> |
The length of the key field. |
<KEYPRECISION> |
Precision of key field. |
<KEYSCALE> |
Scale of key field. |
<COMMENT> |
Column comment |
IMS Field Type |
COBOL Native Type |
COBOL Usage Representation |
SQL Type |
---|---|---|---|
P |
DISPLAY_NUMERIC |
PIC S9(n)V9(0) COMP-3 |
Decimal |
C |
CHARACTER |
PIC X(n) |
Char |
F |
BINARY |
PIC S9(9) COMP |
Integer |
H |
BINARY |
PIC S9(4) COMP |
SmallInt |
The following is an example of an IMS Index Text Specification file:
* this is a sample IMS Index Text Specification file
* lines that start with an '*' are comment lines and are not processed as part of the import
CNX1CUST,CUST1FL,CUST1FLD,CUSTOMER,,CUSTID,C,0,5,0,0
CNX1CUST,CUST1FL,CUST1FLD,ORDERS,CUSTOMER,ORDERID,P,0,4,7,3,This is a comment
The first two lines have an '*' in the first column and are therefore commented out. The file contains the definitions for two segments, CUSTOMER and ORDERS. ORDERS is a child of CUSTOMER. On the line for CUSTOMER, the PARENTSEGMENTNAME is empty (represented by the ',,' between the segment name and the key name) because it does not have a parent.
Note: The entire hierarchy for a segment must be represented in this file. If a segment has an entry for the parent segment name, there must also be an entry for the parent segment. If the hierarchy is not represented all the way to the root segment, an error will occur and the segment will not be imported.
To perform an IMS Index text specification file import, select this option from the import screen.
In addition to specifying the HLQ, SSID and PSB name, you must also specify the location and name of the Index Text Specification file as well as the fully qualified name of the COBOL copybook. For information on specifying COBOL copybooks, see the section Importing IMS files using COBOL FD. CONNX will use the information in the specification file rather than calling into the IMS Library Integrity Utilities for this information.
Importing IMS files using COBOL FD files