Updating FDs from a COBOL Source File or Relativity Symbol Table

  1. With a catalog open in the Relativity Designer, on the Tools menu, click Update FDs from Source.

    The COBOL FD Importer tab is displayed in 'Updating FD from Source' mode. If you opened the COBOL FD Importer tab from the File menu, this mode is not enabled and you will be unable to perform the merge process with existing file definitions.

  2. In the Import FDs From field, select the type of update:
    • Update from a COBOL source (.cbl) file:
      CAUTION:
      Only use a source file that contains well-formed COBOL syntax that compiles cleanly.
      1. In the Import FDs From field, select RM/COBOL Source File using RST Schema Extractor (.cbl -> .rst).
      2. To the right of the Files to Import field, click (Select file to import), then use the Open dialog box to select a .cbl file.
      3. If necessary, enter the appropriate compiler (directive) options in the Compilation Options field.
      4. If the FD includes copy files, click (Select file to import) and select the folder(s) in which the copy files(s) reside.
        Note: If you are having issues with the update, you may be requested to perform it with Keep Temporary Files after Import selected, which retains the temporary files created during the update process; SupportLine can use the .lst and .err.xml temporary files to help troubleshoot update issues.
    • Update from an RM/COBOL object (.cob) file:
      1. In the Import FDs From field, select RM/COBOL Object File (*.cob).
      2. To the right of the Files to Import field, click (Select file to import), then use the Open dialog box to select a .cob file.
    • Update from an Relativity Symbol Table (.rst) file:
      1. In the Import FDs From field, select RST Schema File (*.rst).
      2. To the right of the Files to Import field, click (Select file to import), then use the Open dialog box to select an .rst file.
  3. Click Read File and Record Descriptions.

    A further two tabs are displayed. The Items to Import tab displays the FDs found in the selected file, and the Messages tab contains output from the Schema Extractor process.

  4. In the Items to Import tab, select the file definition(s) to update, then click Add to Catalog.
    Note: If you need to import other COBOL items from the source that are not part of the file definition (e.g. working-storage items), click Show Advanced Import Options, then select from the additional items displayed.

    For each selected file definition, an additional Update... tab containing a merge editor is displayed. Each FD is compared with the original FD, and an attempt is made to auto-resolve each field in the record.

  5. For each tab, deal with any items that require attention, as indicated by 'Unmatched' in the Matches column:
    1. Click the row containing Unmatched in the Matches column.

      Details of the difference between the original and new field are displayed.

    2. Click Unmatched, and then select a new status:
      • Select New if the item is a new addition to the FD.
      • Select Delete if the item is to be deleted from the FD.

    Once all unmatched fields are resolved, the Complete Merge for FD option becomes available.

  6. Click Complete Merge for FD.

    The updated file definition is now displayed in the Catalog Explorer. The existing file definition is still available in the Catalog Explorer, but has (Previous) appended to its name, and any tables associated with the previous FD have 'OLD' appended to their name. You can delete this file definition if it is no longer required, but first you must delete any existing table definitions for that file definition.