Generating UNDO or REDO DDL Statements

The DDL Activity function can be used to generate executable DDL statements to redo the creation of or undo the dropping of an object. The UNDO DDL option lets you recover from an accidental drop. The REDO DDL option can be used to recreate source objects in a mirror table.
caladb2
The DDL Activity function can be used to generate executable DDL statements to redo the creation of or undo the dropping of an object. The UNDO DDL option lets you recover from an accidental drop. The REDO DDL option can be used to recreate source objects in a mirror table.
The DDL statements that are generated provide a starting point for writing the DDL.
CA Log Analyzer™ for DB2 for z/OS
attempts to generate complete DDL statements, but we recommend reviewing the statements before using them.
DDL is not generated for ALTER statements.
Follow these steps:
  1. Select 
    (Process Log) from the
    CA Log Analyzer™ for DB2 for z/OS
     Main Menu and press Enter.
    The Report Specification panel appears.
  2. Select DDL Activity and press Enter.
    The DDL Activity Report Options panel appears.
  3. Complete the following fields:
    • Type
      U
      (to create UNDO DDL) or
      D
      (to create REDO DDL) in the Output Format Field.
    • Type
      D
      (Detail) in the Level of Detail field.
    • (Optional) Use the log data filter options to filter the data that is included in the DDL statements.
    • (Optional) Use the miscellaneous options to include or exclude other types of data from the DDL statements. You can also specify whether to generate table OBIDs.
  4. Press PF3 (End) repeatedly until the Report Source Specification panel appears.
  5. Specify the log data to analyze by entering the starting and ending parameters under LOG PROCESSING RANGE and the data sources to use under SOURCE OPTIONS.
    To enter a log label name or a date/time expression that exceeds the field length in the panel, enter a slash (
    /
    ) in the field and press Enter. The expanded field pops up. Enter the value in the field and press PF3 (End).
    Press PF3 (End).
    The Output Specifications panel appears.
  6. Enter a data set name for the DDL statements in the Dataset Name field and press PF3 (End).
    • If you included LOB column data in your report options, a second Output Specifications panel appears. Go to Step 7.
    • If you excluded LOB column data, the Report Submission panel appears. Go to Step 8.
  7. Enter a data set name for the LOB file.
    Press PF3 (End).
    The Report Submission panel appears.
  8. Specify an execution mode and press Enter.
    The DDL statements are generated and saved to the specified destination.