About dbutility redefine

Use the redefine command in the following circumstances:

  • When the SUPPORT entry in the DBServer control file has changed.
  • When a data set is reorganized or is being remapped.

Reorganized Data Sets

When a data set has been reorganized (status_bits = 8), the redefine command compares the data set layout in the existing client control tables with the new layout and does the following:

  • If the layout of any of the tables mapped from the data set has not changed, the redefine command sets the data set ds_mode to 2, indicating that the data set is ready to be updated.
  • For all tables for which the layout has changed, the redefine command creates reorganization scripts that will alter the relational database tables to match the changes in the reorganized DMSII data sets.
  • If new columns appear as a result of a DMSII update, the DATABridge Client does one of the following (depending on the value of the suppress_new_column parameter):

     

    suppress_new_columns

    Result

     

    If the value is True

    DATABridge Client sets the active column to 0 for the new items in the DATAITEMS table as well as the new tables in the DATATABLES client control table that were derived from a reorganized data set.

    The next process command does not reclone the data set.

     

    If the value is False

    The redefine command and reorg commands alter the client database, adding the new structures, but with empty values. The next process command will continue to populate the table, including the new column.

  • If a new data set appears as a result of a DMSII update, the program does one of the following (depending on the value of the suppress_new_datasets configuration file parameter):

     

    suppress_new_datasets

    Result

     

    If the value is True

    DATABridge Client sets the active column in the corresponding entry in the DATASETS client control table to 0, and the data set is not mapped.

     

    If the value is False

    DATABridge Client sets the active column in the corresponding entry in the DATASETS client control table to 1 (unless the data set is a REMAP), and the layout of the corresponding relational database tables is defined in the DATATABLES and DATAITEMS client control tables.

    You must run a reorg or generate command to create the scripts for these new tables. These data sets are automatically cloned the next time you run a process command.

  • If any data set whose active column is 0 is reorganized, the redefine command updates the corresponding client control table entries, while leaving the active column of the data set at 0. This ensures that if you later decide to clone that data set, all you need to do is to set the active column to 1 and execute a redefine and a generate command.