Groups | Blog | Home
all groups > sql server dts > september 2004 >

sql server dts : import data to table with Identity column?


Ron
9/28/2004 10:51:36 AM
Hello,

I tried running DTS to import data from a text file to a
Sql Server 2000 table which contains an Identity column
(autonumber column). I got an error that the Identity
column cannot be null. I used to be able to import this
file before I added the Identity column. Is there a way
to import data to a table with an Identity column?

Original table had 10 columns. Textfile has 10 columns,
1st row is column headings. Now the table has 11 columns
(with the Identity column). In the DTS wizard, the table
columns all matched the text file columns. Identity
Column on its own.

What do I need to do to be able to import the data?

Thanks,
Ron
9/28/2004 11:48:50 AM
I was checking around the web for information and a few
sites suggest that there is an Ignore Identity Column
feature somewhere in column mappings/Transformations, but
I don't see it. Any suggestions appreciated.


[quoted text, click to view]
Ron
9/28/2004 11:57:31 AM
OK. I figured this out. I went to the Transformations
tab, to Column Mappings, and on the Identity Column Source
field I clicked the down Arraw and found the Ignore
selection. Then I unchecked "Enable Identity Insert".
And now I can import my data again. And I get my
autonumbers, as desired.


[quoted text, click to view]
AddThis Social Bookmark Button