[Mono-list] SqlBulkCopy Error: Incorrect syntax near ','

Lazar knk5n at virginia.edu
Mon Jul 6 19:04:11 EDT 2009




Gonzalo Paniagua Javier-5 wrote:
> 
> On Tue, 2009-06-30 at 13:56 -0700, Lazar wrote:
>> Hi there,
>> 
>> I am trying to use mono to import data into a Microsoft SQL Server from a
>> Linux machine. The code is written in C# and makes use of the SqlBulkCopy
>> class. The program runs just fine on a Windows platform, and there are no
>> issues discovered when checked with the Mono Migration Analyzer. When the
>> program is executed under mono (both versions 2.0.1 and 2.4.2 have been
>> tried) on a machine running Ubuntu 9.04 it runs fine until it gets to the
>> WriteToServer(DataTable) call, and then the following error is displayed:
>> 
>> Incorrect syntax near ','.
>> System.Data.SqlClient.SqlException: Incorrect syntax near ','.
>>   at System.Data.SqlClient.SqlConnection.ErrorHandler (System.Object
>> sender,
> 
> We're going to need more information in order to debug this. Could you
> provide a small program with the smallest statement possible that
> reproduces the problem? If so -> http://mono-project.com/Bugzilla.
> 
> Thanks.
> 
> -Gonzalo
> 
> 
> _______________________________________________
> Mono-list maillist  -  Mono-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
> 
>  http://www.nabble.com/file/p24364374/Program.cs Program.cs 

I have attached a simple program that exhibits the problem. It connects to a
SQL Server that has a database with a table that has 3 columns - "timestep",
"zindex", "data". Again, it works on machines running Windows, but not on
Linux with mono or monodevelop for that matter.

Thank you,

Kalin

-- 
View this message in context: http://www.nabble.com/SqlBulkCopy-Error%3A-Incorrect-syntax-near-%27%2C%27-tp24279469p24364374.html
Sent from the Mono - General mailing list archive at Nabble.com.



More information about the Mono-list mailing list