About this task
This command performs preparatory tasks
before performing an upgrade. This includes getting the size of tables
to determine which tables will take longer to upgrade, and dropping
the views. This information is used later when performing the actual
upgrade so as to minimize the time.
It then uses
the size information available, and performs alterations to the transaction
tables. After this task is performed, the transaction tables will
have new columns and data. Values in the transaction tables are trimmed
for the data types that have been changed in the newer version.
Note: If
you set the
yfs.apply.sql.manually property to Y
in the
<INSTALL_DIR>/Migration/9.3/buildmigration.properties file,
you must manually apply the following DDLs before running the alter-transaction-tables
target:
- <INSTALL_DIR>/Migration/<previous version directory>/database/scripts/<dbtype>/transaction/uniqueindexdrops.sql
- <INSTALL_DIR>/Migration/<previous version directory>/database/scripts/<dbtype>/transaction/indexdrops.sql
- <INSTALL_DIR>/Migration/<previous version directory>/database/scripts/<dbtype>/transaction/alters.sql
- <INSTALL_DIR>/Migration/<previous version directory>/database/scripts/<dbtype>/transaction/seq.sql
where
<previous version directory> corresponds
to the location of the previous version directory and
<dbtype> corresponds
to the database type (DB2 or Oracle). However, when upgrading from
Release 8.2 (or earlier), exclude alters in the above files that belong
to tables mentioned against the
yfs.migrator.exclude.tables property
in the
<INSTALL_DIR>/Migration/<previous version
directory>/buildmigration.properties file.
- When migrating from 8.0, 8.2, 8.5, 9.0, 9.1, 9.2,
9.2.1 or 9.3 to 9.4, run the following command:
${ANT_HOME}/bin/ant
-Druntime=<INSTALL_DIR> -Druntime.old=<INSTALL_DIR_OLD>
-f buildmigration.xml -logfile <logfile> -Dtarget=alter-transaction-tables
migrate
The following *.done files
are created in the 9.3 status folder by the alter-transaction-tables
task:
- ant_dropviews.xml.done
- transaction_ant_altertables.xml.done
If you encounter any error when altering transaction
tables, fix the cause of the error and perform the task of altering
transaction tables again. Before executing the task, change the value
of the onerror attribute from "abort" to "continue"
in the <INSTALL_DIR>/Migration/9.3/transaction/ant_altertables.xml file.
The onerror attribute specifies how
to proceed when an error occurs during the execution of one of the
statements. The valid values are:
- Continue - Indicates that on encountering an error,
proceed with the task of altering other tables.
- Abort - Indicates that on encountering an error,
do not proceed with the task of altering other tables.
Note: If you dropped an index in an earlier release and the
index is changed in the current release, an error occurs when altering
transaction tables. Analyze the index changes to determine whether
or not you want the index dropped. If you want the index dropped,
drop the index after the upgrade.