Migration overview and considerations


The BMC AMI Log Master for Db2 product can use the information stored in log records to generate SQL statements or output load files.

You can migrate data changes on an ongoing basis or an ad hoc basis, and specify log scans, reports, and file outputs to:

  • Migrate changes to shadow tables after an initial full migration
  • Migrate specific updates to another system for test or audit
  • Build load data that reflects the changes to audit on another system

After you create a set of shadow tables, BMC AMI Log Master can use the information from log records to generate SQL statements. You can execute these statements against your shadow tables to bring them up-to-date. Use the following features to enhance this capability:

  • Select only certain columns for migration.
  • Include or exclude updates caused by referential integrity.
  • Include or exclude updates caused by activity defined within a trigger.
  • Migrate only complete transactions and automatically stage incomplete transactions for the next migration (using a special type of BMC AMI Log Master log scan called an ongoing log scan).
  • Create output load files for bulk migration. 

Ongoing processing

You must use ongoing processing for any sequential migration tasks to avoid missed data.

When a job is an ongoing job, BMC AMI Log Master automatically adjusts the range of the time frame to begin when the last log scan ended. In addition, open transactions at this point are staged, and are included if they are complete in the new time frame.

As the following figure shows, the possibility of missing data exists, even when you use a log mark with quiesce as the start point of a log scan. In this figure, the log scan begins after the start of the unit of recovery. The first update to the relevant table in the unit of recovery takes place after the start point (log mark with quiesce). Because the start point of the log scan is after the start of the unit of recovery, BMC AMI Log Master will not include all transactions associated with the unit of recovery in the log scan output.

GUID-712F9E98-80C3-4A88-BA24-AC3722090F2B-low.png

For more information about ongoing processing, see Command-and-syntax-reference.

Special circumstances in the Db2 log

Before you move data to a new location, be aware of special circumstances that can occur in the Db2 log that you might need to accommodate.

For example, when BMC AMI Log Master scans the Db2 log records resulting from certain load actions, it can encounter log records that cause it to generate SQL statements that, when executed, result in negative SQL codes. Similarly, if the load action includes duplicate rows in the data that is loaded, you can encounter negative SQL codes. For more information about special considerations for output files and SQL, see the section about Considerations-for-output-files-and-SQL.

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*