Importing Metadata from COBOL Copybooks
After the CONNX TCP/IP listener program is started as a batch job, the next step is to use the CONNX Data Dictionary Manager program to import metadata from COBOL copybooks into a CONNX Data Dictionary file. The following steps show how to import metadata for the CONNX sample VSAM customer KSDS (Key Sequenced Data Set) file:
1. Run CONNX Data Dictionary.
2. In the CONNX Data Dictionary Manager, click Import.
The Import CDD dialog box appears.
3. Select VSAM COBOL FD files from the Import Type list box.
4. In the Enter a COBOL FD data set member text box, enter CONNX.STASK.COPYBOOK (CUSTOMER).
By default CONNX will use FTP to import the copybook. To import without FTP add the following configuration setting:
With FTPIMPORT set to 0, the copybook must reside on the PC where the import is being performed (in ASCII). Specify the path to the copybook. Wildcard imports are not permitted in this mode.
5. In the Server text box, enter the symbolic or dotted numeric TCP/IP address of the target host, and then enter your TSO user name and password. Enter the TCP/IP port number defined by the =CNXRUNPORT environment variable entry in the CNXPARMS member of the CONNX.STASK.CNTL partitioned data set as described in
Verifying the CONNX Started Task Components Installation. 6. Select a database container in the destination database list box.
7. Click OK.
8. Select the CUSTOMERS_VSAM table. The Table Properties tab appears with the CICS File Name text box set to UNKNOWN.FILE.
9. For VSAM files, the file layouts are maintained separately from the physical or logical file name (fully qualified JCL DSN or DDNAME, respectively). The CNXVSAM JCL procedure defines standard DDNAMES for the CONNX sample VSAM files. For the CONNX sample VSAM Key-Sequenced Data Set (KSDS) CUSTOMER file, the DDNAME is CNXCSTK. Change UNKNOWN.FILE with CNXCSTK.
10. Press <Tab> to open the CONNX Database Logon dialog box.
Enter your TSO user ID and password, and the correct TCP/IP port number, and then click OK. A successful import of the CNXCSTK file locates a primary key (index) on the CUSTOMERID field, which can be displayed by clicking the Table Indexes tab.
11. To import additional CONNX sample KSDS files, refer to CONNX.STASK.COPYBOOK(@INDEX) for sample CONNX COBOL copybooks and VSAM/QSAM JCL DDNAMES, and repeat steps 5-10.
12. After importing one or more CONNX sample VSAM files, save the information in a CONNX CDD file, define an ODBC data source which points to the new CDD file, and use the CONNX InfoNaut Query Tool to execute queries against the tables defined in the ODBC data source.
For more information on creating CONNX ODBC data sources and connecting to them with InfoNaut, refer to Testing a Database Connection.