Take the 2-minute tour ×  Given a column structure in a CSV file
of:  First_Name, Last_Name, Date_Of_Birth  And a SQL Server
table with a structure of  ID(PK) | First_Name | Last_Name |
Date_Of_Birth  (Field ID is an Identity with an auto-increment
of 1)  How do i arrange it so that SQL Server does not attempt
to insert the First_Name column from the csv file into the ID
field?  For info the csv is loaded into a DataTable and then
copied to SQL Server using SqlBulkCopy  Should i be modifying
the csv file before the import add the ID column (The
destination table is truncated prior to import, so no need to
worry about duplicate key values.) Or perhaps adding an id
column to the Datatable?  Or Is there a setting in Sql Server
that i may have missed?  share|improve this question add comment
2 Answers  up vote 0 down vote accepted  You should add the ID
column to the datatable, but do not worry about populating that
field with data from the CSV.  Once that is done the data should
line up fine and since ID is a I