I am using the SQL Server Import and Export wizard to import data from an Excel sheet into an existing table in my database. I want to append the data to the existing data, however I am stuck on figuring out how to keep the primary key in this table incrementing with the data I import. I don't have the [ID]
column in my Excel sheet. The last value in my [ID]
column is 105, so I would like for it to continue from there once I import.
Is there any way to do this through the wizard? I've tried the "Enable Identity Insert" check box in the column mappings window, however I still receive an error that I can not insert null values
It should be simple. Alter your ID column as identity
column increment by 1 and while importing data from your excel, don't map or do anything to this column. Just import all other columns without Enabling Identity Insert check box