column Id in table is identity ,how to update column id to sql tables importing from CSV
Loading
column Id in table is identity ,how to update column id to sql tables importing from CSV
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Jignesh KumarPosted Mar 13, 2023, 11:42 AM
Hello MEghana,
You can refer this one which will help you out,
https://www.c-sharpcorner.com/UploadFile/0c1bb2/inserting-csv-file-records-into-sql-server-database-using-as/
Amit MohantyPosted Mar 13, 2023, 10:34 AM
You can use SqlBulkCopy object to copy data from the CSV file to the database table.
Meghana MPosted Mar 13, 2023, 7:53 AM
not using import wizard ,using C# console application
Jignesh KumarPosted Mar 13, 2023, 7:12 AM
If you are using import wizard then you need to enable insert identity,
https://www.c-sharpcorner.com/article/how-to-import-data-from-excel-data-into-sql-table/