Step 1. Specify the objects and information to migrate
You can migrate object definitions, object data, views, catalog statistics, or any combination of this information for Db2 databases, table spaces, and tables, as well as their dependent objects.
Procedure
To specify the objects and information to migrate:
- On the DB2 Administration Menu (ADB2) panel, specify option 1, and press Enter.
-
On the System Catalog (ADB21)
panel, specify one of the
following options, and press Enter:
- D for databases
- S for table spaces
- T for tables
- V for views
You can use any of these object types as a base to select objects that you want to migrate. -
On the Databases (ADB21D) panel, Table Spaces (ADB21S)
panel, Tables, Views, and Aliases
(ADB21T) panel, or Views (ADB21VV) panel, issue the MIG
primary command or line command.
Tip: If you use the MIG primary command, first filter the list of objects on the panel so that only the objects that you want to migrate are listed.
-
On the Migrate Table Spaces (ADB28S)
panel, Migrate Tables (ADB28T)
panel, or Migrate Views (ADBP8V)
panel, take one of the following
actions:
- To specify the objects individually, modify the list of objects on this panel as needed by using the available commands and line commands. For example, on the Migrate Table Spaces (ADB28S) panel, you can use the MIGARC command to add all related archive table spaces.
- To specify an object scope, do not modify the list of objects on this panel. You can later specify the object scope as part of Step 2. Generate the migration batch jobs.
- Specify the NEXT command.
-
For views, specify
the level at which you want to migrate the view on the DDL Level (ADBP8VO) panel, and press Enter.
- On the Migrate Parameters (ADB28M) panel, specify the GEN option, and press Enter.
-
On the Generate SQL from DB2 catalog
(ADBP8MG) panel, specify the SQL
statements that you want generated for the migration, and press Enter:
-
On the Migrate Parameters (ADB28M)
panel, specify the following
options to indicate which information you want to migrate:
- Scope of migrate:
- Specify whether you want to migrate DDL, data, and catalog statistics.
- Catalog statistics options:
- Specify the qualifier for the target catalog and the catalog tables that you want
to update.
When you migrate catalog statistics, Db2 Admin Tool generates INSERT, UPDATE, and DELETE statements that modify the catalog statistics. The statements are generated with the qualifier of the target catalog that you specify. The statistic fields that are modified are those fields that are associated with the objects that are being migrated. (The complete list of statistics fields are those fields that are set by RUNSTATS that can be modified and the five statistics columns for table functions in SYSROUTINES, which are not set by RUNSTATS.)
Tip: To control the number of generated statistics, specify SELECT in the Statistics tables field. Later in the process (as part of Step 2. Generate the migration batch jobs), you can select which catalog tables you want to update with statistics.
Keep this panel open. In the next step (Step 2. Generate the migration batch jobs), you will continue entering options on the Migrate Parameters (ADB28M) panel.