INF: How to Use DTS Wizard to Insert Data into SQL Tables with an Identity Column (246310)
The information in this article applies to:
This article was previously published under Q246310 SUMMARY
The Data Transformation Services (DTS) Wizard provides a method to insert data into a table that contains an identity column from a source, provided the data contains unique integer values and does not violate constraints imposed on the destination table. For more information, see the first example in the More Information section.
The DTS Wizard also provides a method to insert into a table containing an identity column if the source data DOES NOT contain the unique identity values. In this scenario, non-identity columns only can be the destination from a DTS source. This can be achieved by modifying the DTS package column mappings and by clearing the identity insert option. For more information, refer to the second example in the More Information section.
Executing the package directly, in the second example, without first modifying the package column mappings, results in this error:
DATA TRANSFORMATION SERVICES: Data Pump Exception Log
Error Source: Microsoft OLE DB Provider for SQL Server
Error Description:Cannot insert the value NULL into column 'ID', table 'Test.dbo.T2'; column does not allow nulls. INSERT fails.
Modification Type: | Major | Last Reviewed: | 10/27/2000 |
---|
Keywords: | kbinfo KB246310 |
---|
|