Importing Statistics - Oracle 8i

If statistics are requested at export time and analyzer statistics are available for a table, Export will place the ANALYZE command to recalculate the statistics for the table into the dump file. In certain circumstances, Export will also write the precalculated optimizer statistics for tables, indexes, and columns to the dump file.

Because of the time it takes to perform an ANALYZE statement, it is usually preferable for Import to use the precalculated optimizer statistics for a table (and its indexes and columns), rather than executing the ANALYZE statement saved by Export. However, in the following cases, Import will ignore the precomputed statistics because they are potentially unreliable:

  • Character set translations between the dump file and the import client and the import database could potentially change collating sequences that are implicit in the precalculated statistics.
  • Row errors occurred while importing the table.
  • A partition level import is performed (column statistics will no longer be accurate).

Note: Specifying ROWS=N will not prevent the use of precomputed statistics. This feature allows plan generation for queries to be tuned in a nonproduction database using statistics from a production database.

In certain situations, the importer might want to always use ANALYZE statements rather than precomputed statistics. For example, the statistics gathered from a fragmented database may not be relevant when the data is imported in a compressed form. In these cases, the importer may specifyRECALCULATE_STATISTICS=Y to force the recalculation of statistics.

If you do not want any statistics to be established by Import, you can specify ANALYZE=N, in which case, the RECALCULATE_STATISTICS parameter is ignored.


All rights reserved © 2018 Wisdom IT Services India Pvt. Ltd DMCA.com Protection Status

Oracle 8i Topics