[freetds] bcp error with MS SQL

James K. Lowden jklowden at freetds.org
Tue Aug 16 22:34:27 EDT 2005


Schrama, eric (IT) wrote:
> I have been trying to bcp from Linux to SQL Server 2000.  So far I have
> been have been able to bcp out from SQL Server but cannot bcp from Linux
> to SQL Server.  A simple test of loading a 1 integer column table always
> results in bad data being loaded.  The numbers loaded are completely
> unrelated to the source files (i.e. 1 loads as 17293822569102704640).
> When I bcp out the data file is created on my Linux server without
> issue.  The crazy thing is when I bcp the same file back into SQL Server
> it productes the crazy integers in the SQL table.  To me this looks like
> some sort of locale or character set mismatch.   I am unsure where to
> begin.

Please post the entire TDSDUMP log for the simple 1-column 1-row failed
upload.  If the wrong data are being transmitted to the server, the log
will show it.  I don't see how locale settings can affect bcp of integer
data and ASCII characters.  

--jkl


More information about the FreeTDS mailing list