Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
Ali.M.Habib
Yak Posting Veteran
54 Posts |
Posted - 2009-08-24 : 03:20:58
|
I face a problem wich is when try to bulk insert give me the following errorMsg 4864, Level 16, State 1, Line 1Bulk load data conversion error (type mismatch or invalid character for the specified codepage) for row 1, column 1 (x).Msg 4864, Level 16, State 1, Line 1Bulk load data conversion error (type mismatch or invalid character for the specified codepage) for row 2, column 1 (x).Msg 4864, Level 16, State 1, Line 1Bulk load data conversion error (type mismatch or invalid character for the specified codepage) for row 3, column 1 (x).the target table and source table have the same datatype for example [code="sql"]CREATE TABLE [try] ( [x] [int] NULL , [y] [char] (10) ) ON [PRIMARY]GO[/code]the bcp bulc copy I use is :[code="sql"]bcp master.bcp.%1 out c:\%1.txt -N -S1.1.1.1 -UXXX -PXXX -C1252 -r\n -t, [/code]the bulk insert code is :[code="sql"]BULK INSERT [try] FROM 'c:\try.txt' WITH ( FIELDTERMINATOR = ',', ROWTERMINATOR = '\n' )[/code]example of the data in the source table1 ,Ali2, Mahmoud Any help please |
|
hadi teo
Starting Member
4 Posts |
Posted - 2009-09-16 : 18:56:36
|
Maybe this would help ? http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=86356 |
|
|
|
|
|
|
|