About Copying View Definition and View Data - Teradata Data Mover

Teradata Data Mover User Guide

Product
Teradata Data Mover
Release Number
16.00
Published
December 2016
Language
English (United States)
Last Update
2018-03-29
dita:mapPath
rdo1467305237457.ditamap
dita:ditavalPath
ft:empty
dita:id
B035-4101
lifecycle
previous
Product Category
Analytical Ecosystem

This feature enables you to copy a view definition and the underlying view data from a source system to a target system.

You must use TPTAPI_UPDATE, TPTAPI_STREAM, or JDBC to copy view data. The ARC and TPTAPI_LOAD operators cannot be used to copy view data. ARC cannot be used to copy view data because it does not support that functionality. TPTAPI_LOAD cannot be used to copy view data because the target or staging table that Data Mover creates is a multiset table and TPTAPI_LOAD does not support loading.

Restrictions When Copying Data From the Underlying View

The following restrictions apply when copying data from the underlying view:
  • ARC/TPTAPI_LOAD cannot be used as the load utility when moving underlying data from the view.
  • You cannot move an entire database when moving view data since ARC is the only supported utility to move entire databases.

Row Count Validation

You can validate the row counts of the source view and the target table after copying data from the underlying view. In order to perform row count validation, the validate_row_count element must be specified for the view.
<views>
		<view selection="included" copyData="true">
 		<name>deptsals</name>
			<database>MyDb</database>
			<view_data_table>
				<target_table>TargetTable</target_table>
				<target_database>TargetDb</target_database>
			</view_data_table>

			<staging_database>
				<name>TargetDb_Staging</name>
			</staging_database>

 		<validate_row_count>ALL</validate_row_count
 </view>
</views>

When copying View data to a target view, the validate_row_count element validates the row counts of the source view and the target view.

Valid values for validate_row_count are ALL, PARTIAL, or NONE. The results of the row count validation can be seen in the status output. The row count validation is only performed when copying data from the view (copyData="true"). When copying only the view definition (copyData="false"), the row count validation is not performed even if the validate_row_count element is specified for the view.

Views cannot be copied between Teradata and Aster or Hadoop systems.