You are here: Re: bulk copy error: Received invalid row length x from bcp client. Minimum row size is y « MsSQL Server « IT news, forums, messages
Re: bulk copy error: Received invalid row length x from bcp client. Minimum row size is y

Posted by Erland Sommarskog on 10/01/43 11:19

Patrick Dunnigan (pdunnigan@adelphia.net) writes:
> I am attempting a bulk copy from a c program into SQL Server 2000 using
> DBLib in freeTDS 0.63 RC11 (gcc 3.4.3, RH 9). I am getting an error
> message that I cannot find any documentation on.
>
> The server is sending back the following: "Received invalid row length 2
> from bcp client. Minimum row size is 4."
>
> I know the row is longer 2 bytes (see below). Once this happened I
> created a test table and C program. See below. Anyone with any ideas?

I made the necessary changes to your program for it to run with
the DB-Library that comes with SQL Server, and it ran successfully.

So I would strongly suspect that the problem is with the DBLib that
you are using. The error message is obscure, but it probably means
that the client API has messed up.

The only thing I found a but funny in your script is that you don't call
BCP_SETL, which is mandatory for DB-Library for SQL Server. But if that
would be necssary, not even bcp_init would work.

--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinfo/productdoc/2000/books.asp

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация