Hi, Everyone; I have an error with the bulk insert, this is my first time trying it. I screen shot below my issue. The First row is equal to 1 because that is my header.
If the first row is header, specify FIRSTOW = 2.
Also, you might try omitting the ROWTERMINATOR line, in which case it defaults to '\n' (I think).
The other and obvious reason, which you probably have already eliminated, is that the column width might be too small for the data.
It's a good idea to import text data into a staging table with nvarchar(max)
columns, then you can perform checks on the data to make sure it is correct and compatible with the destination table.
Thanks for your input. I did some further inspecting and I realize that some column value have comma in between the the double quotes. This causing the bulk insert to not split it properly. I open to any suggestion on how to handle this.
ThanksThank you for your input. After further inspection, I've noticed that some column values contain commas within the double quotes. This is causing the bulk insert to fail to split the values correctly. I would appreciate any suggestions on how to handle this issue.
Thank you!
I solved it. I use the find and replace method to removed the commas.