Share via


Data Conversion Transformation

The Data Conversion transformation converts the data in an input column to a different data type and then copies it to a new output column. For example, a package can extract data from multiple sources, and then use this transformation to convert columns to the data type required by the destination data store. You can apply multiple conversions to a single input column.

Using this transformation, a package can perform the following types of data conversions:

  • Change the data type. For more information, see Integration Services Data Types.

    Note

    If you are converting data to a date or a datetime data type, the date in the output column is in the ISO format, although the locale preference may specify a different format.

  • Set the column length of string data and the precision and scale on numeric data. For more information, see Precision, Scale, and Length (Transact-SQL).

  • Specify a code page. For more information, see Comparing String Data.

    Note

    When copying between columns with a string data type, the two columns must use the same code page.

If the length of an output column of string data is shorter than the length of its corresponding input column, the output data is truncated. For more information, see Error Handling in Data.

This transformation has one input, one output, and one error output.

You can set properties through the SSIS Designer or programmatically. For information about using the Data Conversion Transformation in the SSIS Designer, see Convert Data to a Different Data Type by Using the Data Conversion Transformation and Data Conversion Transformation Editor. For information about setting properties of this transformation programmatically, see Common Properties and Transformation Custom Properties.

Blog entry, Performance Comparison between Data Type Conversion Techniques in SSIS 2008, on blogs.msdn.com.

See Also

Fast Parse
Data Flow
Integration Services Transformations