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 |
pascal_jimi
Posting Yak Master
167 Posts |
Posted - 2014-01-15 : 05:36:06
|
hi friends want to do an bulk insert but get an errorMessage 8152, Level 16, State 9, Line 1String or binary data would be truncated.The statement has been terminated.here's the sql codeCREATE TABLE myTable99(Test char(7), Test1 char(60), Test2 char(2), Test3 char(4), Test4 char(4), Test5 char(25), Test6 char(11),Test7 char(7), Test8 char(10), Test9 char(8),Test10 char(10), Test11 char(10), Test12 char(7))exec xp_cmdshell 'bcp DB_BOOKS.dbo.myTable99 format nul -S XIRDALAN-SERVER -f "c:\temp\myTable.fmt" -c -T' select @@servernamethis is fmt file 8.0131 SQLCHAR 0 7 "" 1 Test Cyrillic_General_CI_AS2 SQLCHAR 0 60 "" 2 Test1 Cyrillic_General_CI_AS3 SQLCHAR 0 2 "" 3 Test2 Cyrillic_General_CI_AS4 SQLCHAR 0 4 "" 4 Test3 Cyrillic_General_CI_AS5 SQLCHAR 0 4 "" 5 Test4 Cyrillic_General_CI_AS6 SQLCHAR 0 25 "" 6 Test5 Cyrillic_General_CI_AS7 SQLCHAR 0 11 "" 7 Test6 Cyrillic_General_CI_AS8 SQLCHAR 0 7 "" 8 Test7 Cyrillic_General_CI_AS9 SQLCHAR 0 10 "" 9 Test8 Cyrillic_General_CI_AS10 SQLCHAR 0 8 "" 10 Test9 Cyrillic_General_CI_AS11 SQLCHAR 0 10 "" 11 Test10 Cyrillic_General_CI_AS12 SQLCHAR 0 10 "" 12 Test11 Cyrillic_General_CI_AS13 SQLCHAR 0 7 "\r\n" 13 Test12 Cyrillic_General_CI_ASBULK INSERT myTable99FROM 'C:\abs040123.txt'WITH (FORMATFILE = 'c:\temp\myTable.fmt')i get errorMessage 8152, Level 16, State 9, Line 1String or binary data would be truncated.The statement has been terminated.text file in this adresshttps://docs.google.com/file/d/0B3LMe3WzKs3TZ21sRGhSTGFZeDQ/edithttp://sql-az.tr.gg/ |
|
pascal_jimi
Posting Yak Master
167 Posts |
Posted - 2014-01-16 : 02:04:56
|
my friends are the same PROFESSIONALSnobody can import this file?http://sql-az.tr.gg/ |
 |
|
|
|
|
|
|