[Mono-devel-list] RE: [Gc] [PATCH] Race condition when restarting threads

2005-07-12 Thread Ben Maurer
On Tue, 2005-07-12 at 11:42 -0700, Boehm, Hans wrote:
> > Your patch had the fields set as volatile, so shouldn't the 
> > compiler ensure that the cpu does not reorder the stores?
> We had a long discussion of that on the C++ memory model list.
> The answer is architecture dependent.  Volatile will generally
> prevent compiler reordering.  It usually introduces the necessary
> hardware barriers on Itanium, but not, for example, on PowerPC.

I think your version has a race if this is the case:

> +sigsuspend(&suspend_handler_mask);/* Wait for signal */
> +while (GC_world_is_stopped && GC_stop_count == my_stop_count) {

Imagine that this thread gets a spurious signal. The GC_stop_count++
statement has already taken effect, but the GC_world_is_stopped = TRUE
has not, the thread would bypass the wait, causing the world not to be
stopped.

In fact, how do we know that my_stop_count is correct?

When I put this in the mono tree, I'd really have something with
barriers in it and use the version that I suggested. Without the
barriers, am a bit worried about the correctness (especially since the
issues happen on platforms I am not testing with).

-- Ben

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


RE: [Mono-devel-list] DateTime Parameters in MSSQL Server

2005-07-12 Thread John BouAntoun
Hi guys,

Just thought I'd add my 2 cents worth.

Being from australia, I'm quite used to dealing with badly coded software -> 
SQL date handling.

In the Australian locale we have our dates in the format dd/MM/, which is 
the oposite to the US way. 

The way we get around any issues that arise from, for example the webserver 
being set up in an australian locale and the SQL server being set uo in a US 
locale, is to use the abbreviated month name. 

I've found you can't go wrong with using abbreviated month name in either this 
format:

dd MMM 

Or the other way around

MMM dd 

Perhaps we should be doing this when we pass dates into sql server?

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Hubert FONGARNAND
Sent: Wednesday, 13 July 2005 12:40 AM
To: mono-devel-list@lists.ximian.com
Subject: Re: [Mono-devel-list] DateTime Parameters in MSSQL Server

Here's my patch to solve my problem :

I've added an other little modification :
With my patch it's possible (like MS.NET) to pass a byte array with a null 
length as a binary parameter.

Le Mardi 12 Juillet 2005 16:30, Hubert FONGARNAND a écrit :
> Le Mardi 12 Juillet 2005 15:50, Hubert FONGARNAND a écrit :
> I've found where is the problem
>
> Fri Jan 7 08:26:07 2005 suresh has submitted a patch wich change the 
> format of datetime parameters from :
>  value = String.Format(System.Globalization.CultureInfo.InvariantCulture,
>'{0:MM/dd/ hh:mm:ss 
> tt}'", d );
>
> to
> value = String.Format(System.Globalization.CultureInfo.InvariantCulture,
>"'{0:MMM dd  hh:mm:ss tt}'", d );
>
> i've restored the old line (0:MM/dd/ hh:mm:ss tt) and it works for 
> me now! but I think this problems comes from the database culture...
>
> Is it possible that the Tds drivers could adapt it automatically to 
> the database???
> I think, it's a very bad idea to change the mono code source each time 
> you change your database...
>
>
> thanks
>
> > The problems comes from the method
> >
> > private string FormatParameter (TdsMetaParameter parameter)
> >
> > in Mono.Data.tds.protocol
> >
> > wich encode parameters in order to send them to SQL Server. With 
> > MS.NET, parameters are send using a binary format, with mono, 
> > parameters are sent using the "string" format...
> > It's a problem when dealing with dates :
> > case "datetime":
> >DateTime d = (DateTime)parameter.Value;
> > value = 
> > String.Format(System.Globalization.CultureInfo.InvariantCulture,
> >   "'{0:MMM dd 
> >  hh:mm:ss tt}'", d );
> > break;
> >
> > Is the format "MMM dd  hh:mm:ss tt" correct? for all SQL Server 
> > 2000 (french version)
> >
> > Le Mardi 12 Juillet 2005 15:42, Chris van Wyk a écrit :
> > > Hi,
> > >
> > > Datetime has also been giving me huge amounts of problems.
> > >
> > > The work around for me was to convert the item using 
> > > ToString("s"). If you are going to use stored procs, you will need 
> > > to modify your stored proc parameters in the sql statement to string in 
> > > stead of datetime.
> > >
> > > I have also been able to get the Microsoft.ApplicationBlocks.Data 
> > > going with modification to specific DateTime parameter formatting.
> > >
> > > There seems to be problems with the data adapter using the 
> > > sqlhelper from the above. I am getting concurrency errors on 
> > > updates for instance. If someone else has had concurrency errors 
> > > please let me know as I have been able to work round this, but I'm 
> > > not sure if it is a bug in Mono.
> > >
> > > I am using 1.1.7 and have not tested the above on 1.1.8
> > >
> > > Regards
> > > Chris
> > >
> > > > -Original Message-
> > > > From: [EMAIL PROTECTED]
> > > > [mailto:mono-devel-list- [EMAIL PROTECTED] On Behalf Of 
> > > > Hubert FONGARNAND
> > > > Sent: 12 July 2005 03:28 PM
> > > > To: mono-devel-list@lists.ximian.com
> > > > Subject: [Mono-devel-list] DateTime Parameters in MSSQL Server
> > > >
> > > > I've an issue with datetime parameters with MSSQL Server in Mono...
> > > > It seem's that the parameters is badly sent to the SQL Server...
> > > > Please test that :
> > > >
> > > > using System;
> > > > using System.Data;
> > > > using System.Data.SqlClient;
> > > >
> > > > class MainClass
> > > > {
> > > > static string cnx="user id=sa;password=sa;data 
> > > > source=10.69.100.93;initial catalog=Fiche_Produit";
> > > >
> > > >
> > > > public static void Main(string[] args)
> > > > {
> > > > Console.WriteLine("Hello World!");
> > > > SqlCommand cmd=new SqlCommand();
> > > > cmd.Connection=new SqlConnection(cnx);
> > > > cmd.CommandText="INSERT INTO essais (date) VALUES 
> > > > (@date)";
> > > > cmd.Parameters.Clear

[Mono-devel-list] mono + asp.net + cyrillic characters problem

2005-07-12 Thread Slava Petrenko

Hi All!

I tried to run my asp.net site on mono (with mod_apache and with xsp) 
but all cyrillic characters are displayed wrong.
Character set for pages is UTF-8 ( for .aspx and code behind .cs), all 
other stuff has UTF-8 settings too (apache, web.config).
No difference how I run the site - with apache (mod_apache) or with xsp 
(xsp --applications /:/path/to/my_site), results are the same.
Encoding switching within a brower doesn't help, so characters get 
distorted before they get to browser.


Any supposition how to fix that?

Slava.
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] RE: [Gc] [PATCH] Race condition when restarting threads

2005-07-12 Thread Ben Maurer
On Tue, 2005-07-12 at 11:13 -0700, Boehm, Hans wrote:
> I think I generally also prefer your solution.
> 
> But it seems to me that it has a very low probability memory ordering
> issue.
> 
> If I see GC_world_is_stopped set because I'm trying to stop the
> world for the next GC, but I still see the old value of GC_stop_count
> (due to compiler or hardware memory reordering), I think it deadlocks.
> My ugly version will just pause for 25msecs and then recover.
> 
> I think I'll go with your version for GC7, where I have a cleaner
> way of enforcing the memory ordering, and keep my version for 6.6.
> (This assumes we find no other problems.  This stuff is much too
> subtle.)

Your patch had the fields set as volatile, so shouldn't the compiler
ensure that the cpu does not reorder the stores?

What if you only used one field for both the stop count and world is
stopped field (setting the flag for stopped on the highest bit). The
value is only modified in one thread at a time, so you don't have to CAS
or anything. The cpu would be forbidden from reordering writes (they
shouldn't reorder writes to the same field).

-- Ben

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] SQLServer SessionState

2005-07-12 Thread Hubert FONGARNAND
I'm interested by storing sessions state into my pgsql server box...
I've tried to configure my web.config like :


and 


i've created my aspstate database with a table :
CREATE TABLE aspstatetempsessions
(
  sessionid varchar,
  created timestamp,
  expires timestamp,
  timeout numeric,
  staticobjectsdata bytea,
  sessiondata bytea
) 

It seem's to work, but when Mono try to store a session into sessiondata 
column I only get 
000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/000/
...
When Mono tries to retrieve the session it gets an empty one!

what's the problem... 
thanks

___
Ce message et les éventuels documents joints peuvent contenir des informations 
confidentielles.
Au cas où il ne vous serait pas destiné, nous vous remercions de bien vouloir 
le supprimer et en aviser immédiatement l'expéditeur. Toute utilisation de ce 
message non conforme à sa destination, toute diffusion ou publication, totale 
ou partielle et quel qu'en soit le moyen est formellement interdite.
Les communications sur internet n'étant pas sécurisées, l'intégrité de ce 
message n'est pas assurée et la société émettrice ne peut être tenue pour 
responsable de son contenu.
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


re[2]: [Mono-devel-list] Re: mono 1.1.8.2 problems with mdb

2005-07-12 Thread Mike Horsley



Gary
 
no. i'm using 32bit
 SUSE 9.3 pro.
 
thanks
mike
 
> Do you have
 a 64 bit system?  If so, then it wont
 load a 32-bit library (at least it didnt
 for me when I was doing something else).
  Gary M. Smithrud Haley
 Systems, Inc. Phone: 724-934-7853 [EMAIL PROTECTED]
 www.haley.com Moving
 at the Speed of Change From:
 [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]
 On Behalf Of Mike HorsleySent: Tuesday,
 July 12, 2005 11:06 AMTo: Robert Jordan;
 mono-devel-list@lists.ximian.comSubject:
 re: [Mono-devel-list] Re: mono 1.1.8.2 problems
 with mdb  Rob  thanks.
 I checked this RPM and it was not installed.
 I installed it and got the same problem.
   Might there be
 a sequencing issue? e.g., i need to have
 installed readline-devel before installing
 mono?  regards Mike
 > mike,>i downloaded
 the new linux installer for 1.1.8.2, installed
 it. i did>have to set $PATH because
 the new installed so maybe this is indicative>of
 another problem at my end.>>I
 compiled my test app "Main.cs" using -debug>>I
 then tried running mdb and got the following
 error:>>[EMAIL PROTECTED]:~/monotest1>
 mcs -debug Main.cs>[EMAIL PROTECTED]:~/monotest1>
 mdb Main.exe>>Unhandled Exception:
 System.TypeInitializationException: An exception>was
 thrown by the type initializer for>Mono.Debugger.Frontend.GnuReadLine
 ---> System.DllNotFoundException:>libmonodebuggerreadlineYou
 must install the readline-devel RPM.Rob___Mono-devel-list
 mailing listMono-devel-list@lists.ximian.comhttp://lists.ximian.com/mailman/listinfo/mono-devel-list__This
 email has been scanned by the MessageLabs
 Email Security System.For more information
 please visit http://www.messagelabs.com/email
 __<---
 Original Message ---
   From: Robert
 Jordan <[EMAIL PROTECTED]>
 To: mono-devel-list@lists.ximian.com
 Date: Thu, 07 Jul 2005 22:12:39 +0200
 Subject: [Mono-devel-list] Re: mono
 1.1.8.2 problems with mdb   mike,>i
 downloaded the new linux installer for 1.1.8.2,
 installed it. i did>have to set $PATH
 because the new installed so maybe this is
 indicative>of another problem at my
 end.>>I compiled my test app
 "Main.cs" using -debug>>I then
 tried running mdb and got the following error:>>[EMAIL PROTECTED]:~/monotest1>
 mcs -debug Main.cs>[EMAIL PROTECTED]:~/monotest1>
 mdb Main.exe>>Unhandled Exception:
 System.TypeInitializationException: An exception>was
 thrown by the type initializer for>Mono.Debugger.Frontend.GnuReadLine
 ---> System.DllNotFoundException:>libmonodebuggerreadlineYou
 must install the readline-devel RPM.Rob___Mono-devel-list
 mailing listMono-devel-list@lists.ximian.comhttp://lists.ximian.com/mailman/listinfo/mono-devel-list__This
 email has been scanned by the MessageLabs
 Email Security System.For more information
 please visit http://www.messagelabs.com/email
 __
 __This
 email has been scanned by the MessageLabs
 Email Security System.For more information
 please visit http://www.messagelabs.com/email
 __<

--- Original
 Message ---
  
From: "Gary M. Smithrud"
 <[EMAIL PROTECTED]>
To: "Mike Horsley" <[EMAIL PROTECTED]>,
    "Robert Jordan"  <[EMAIL PROTECTED]>,
 
Date: Tue, 12 Jul 2005 11:12:38
 -0400
Subject: RE: [Mono-devel-list]
 Re: mono 1.1.8.2 problems with mdb
  

Do you have a 64
 bit system?  If so, then it won’t
 load a 32-bit library (at least it didn’t
 for me when I was doing something else).
 

Gary M.
 Smithrud
Haley Systems,
 Inc.
Phone: 724-934-7853
[EMAIL PROTECTED]
www.haley.com
Moving at the Speed of Change




From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]
 On Behalf
 Of Mike HorsleySent: Tuesday, July 12,
 2005 11:06 AMTo: Robert Jordan; mono-devel-list@lists.ximian.comSubject:
 re: [Mono-devel-list] Re: mono 1.1.8.2 problems
 with mdb
 

Rob

 

thanks. I checked
 this RPM and it was not installed. I installed
 it and got the same problem. 

 

Might there be
 a sequencing issue? e.g., i need to have
 installed readline-devel before installing
 mono?

 

regards

Mike

> mike,> i downloaded
 the new linux installer for 1.1.8.2, installed
 it. i did> have to set $PATH because
 the new installed so maybe this is indicative>
 of another problem at my end.> >
 I compiled my test app "Main.cs" using -debug>
 > I then tried running mdb and got
 the following error:> > [EMAIL PROTECTED]:~/monotest1>
 mcs -debug Main.cs> [EMAIL PROTECTED]:~/monotest1>
 mdb Main.exe> > Unhandled Exception:
 System.TypeInitializationException: An except

[Mono-devel-list] [PATCH] params attribute missing in System.Array.GetValue and System.Array.SetValue

2005-07-12 Thread Rodrigo B. de Oliveira
Could someone pls review and commit the patch attached to the
following bugzilla issue:

http://bugzilla.ximian.com/show_bug.cgi?id=75516

Thanks!
-- 
bamboo
http://blogs.codehaus.org/people/bamboo/
Got objects? http://www.db4o.com/
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


RE: [Mono-devel-list] Re: mono 1.1.8.2 problems with mdb

2005-07-12 Thread Gary M. Smithrud








Do you have a 64 bit system?  If so, then
it won’t load a 32-bit library (at least it didn’t for me when I
was doing something else).

 



Gary M. Smithrud

Haley Systems, Inc.

Phone: 724-934-7853

[EMAIL PROTECTED]

www.haley.com

Moving at
the Speed of Change











From:
[EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Mike Horsley
Sent: Tuesday, July 12, 2005 11:06
AM
To: Robert Jordan;
mono-devel-list@lists.ximian.com
Subject: re: [Mono-devel-list] Re:
mono 1.1.8.2 problems with mdb



 



Rob





 





thanks. I checked this RPM and it was not
installed. I installed it and got the same problem. 





 





Might there be a sequencing issue? e.g.,
i need to have installed readline-devel before installing mono?





 





regards





Mike





>
mike,

> i downloaded the new linux installer for 1.1.8.2, installed it. i did
> have to set $PATH because the new installed so maybe this is indicative
> of another problem at my end.
> 
> I compiled my test app "Main.cs" using -debug
> 
> I then tried running mdb and got the following error:
> 
> [EMAIL PROTECTED]:~/monotest1> mcs -debug Main.cs
> [EMAIL PROTECTED]:~/monotest1> mdb Main.exe
> 
> Unhandled Exception: System.TypeInitializationException: An exception
> was thrown by the type initializer for
> Mono.Debugger.Frontend.GnuReadLine ---> System.DllNotFoundException:
> libmonodebuggerreadline

You must install the readline-devel RPM.

Rob

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list

__
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email

__

<










--- Original
Message ---





  





From: Robert
Jordan <[EMAIL PROTECTED]>





To: mono-devel-list@lists.ximian.com





Date: Thu, 07 Jul
2005 22:12:39 +0200





Subject: [Mono-devel-list] Re:
mono 1.1.8.2 problems with mdb





  







mike,

> i downloaded the new linux installer for 1.1.8.2, installed it. i did
> have to set $PATH because the new installed so maybe this is indicative
> of another problem at my end.
> 
> I compiled my test app "Main.cs" using -debug
> 
> I then tried running mdb and got the following error:
> 
> [EMAIL PROTECTED]:~/monotest1> mcs -debug Main.cs
> [EMAIL PROTECTED]:~/monotest1> mdb Main.exe
> 
> Unhandled Exception: System.TypeInitializationException: An exception
> was thrown by the type initializer for
> Mono.Debugger.Frontend.GnuReadLine ---> System.DllNotFoundException:
> libmonodebuggerreadline

You must install the readline-devel RPM.

Rob

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list

__
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email

__








___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] RE: [Gc] [PATCH] Race condition when restarting threads

2005-07-12 Thread Ben Maurer
On Mon, 2005-07-11 at 14:15 -0700, Boehm, Hans wrote:
> I've attached a different patch, which I think should solve the
> problem without additional synchronization and context switches,
> at least in the vast majority of cases.  (It should solve the
> problem in all cases.  Additional context switches will be
> needed only if the sigsuspend wakes up early, I claim.)
> 
> Please let me know if you have any problems with this, or if
> this doesn't look right to you.  I tested only superficially.

I'll try to test this as soon as I get a chance.

One question, which is probably a case of me not having any clue about
the code:

> -do {
> -   me->stop_info.signal = 0;
> -   sigsuspend(&suspend_handler_mask);/* Wait for signal */
> -} while (me->stop_info.signal != SIG_THR_RESTART);
> +/* We do not continue until we receive a SIG_THR_RESTART,  */
> +/* but we do not take that as authoritative.  (We may be   */
> +/* accidentally restarted by one of the user signals we*/
> +/* don't block.)  After we receive the signal, we use a*/
> +/* primitive and expensive mechanism to wait until it's*/
> +/* really safe to proceed.  Under normal circumstances,*/
> +/* this code should not be executed.   */
> +sigsuspend(&suspend_handler_mask);/* Wait for signal */
> +while (GC_world_is_stopped && GC_stop_count == my_stop_count) {
> +GC_brief_async_signal_safe_sleep();
> +#   if DEBUG_THREADS
> + GC_err_printf0("Sleeping in signal handler");
> +#   endif
> +}

Why can't you just say

do {
sigsuspend (&suspend_handler_mask);
} while (GC_world_is_stopped && GC_stop_count == my_stop_count);

-- Ben


___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


re: [Mono-devel-list] Re: mono 1.1.8.2 problems with mdb

2005-07-12 Thread Mike Horsley



Rob
 
thanks. I checked
 this RPM and it was not installed. I installed
 it and got the same problem. 
 
Might there be a
 sequencing issue? e.g., i need to have installed
 readline-devel before installing mono?
 
regards
Mike
> mike,>
 i downloaded the new linux installer for
 1.1.8.2, installed it. i did> have
 to set $PATH because the new installed so
 maybe this is indicative> of another
 problem at my end.> > I compiled
 my test app "Main.cs" using -debug>
 > I then tried running mdb and got
 the following error:> > [EMAIL PROTECTED]:~/monotest1>
 mcs -debug Main.cs> [EMAIL PROTECTED]:~/monotest1>
 mdb Main.exe> > Unhandled Exception:
 System.TypeInitializationException: An exception>
 was thrown by the type initializer for>
 Mono.Debugger.Frontend.GnuReadLine --->
 System.DllNotFoundException:> libmonodebuggerreadlineYou
 must install the readline-devel RPM.Rob___Mono-devel-list
 mailing listMono-devel-list@lists.ximian.comhttp://lists.ximian.com/mailman/listinfo/mono-devel-list__This
 email has been scanned by the MessageLabs
 Email Security System.For more information
 please visit http://www.messagelabs.com/email
 __<

--- Original
 Message ---
  
From: Robert Jordan <[EMAIL PROTECTED]>
To: mono-devel-list@lists.ximian.com
Date: Thu, 07 Jul 2005 22:12:39
 +0200
Subject: [Mono-devel-list]
 Re: mono 1.1.8.2 problems with mdb
  
mike,> i downloaded the new
 linux installer for 1.1.8.2, installed it.
 i did> have to set $PATH because the
 new installed so maybe this is indicative>
 of another problem at my end.> >
 I compiled my test app "Main.cs" using -debug>
 > I then tried running mdb and got
 the following error:> > [EMAIL PROTECTED]:~/monotest1>
 mcs -debug Main.cs> [EMAIL PROTECTED]:~/monotest1>
 mdb Main.exe> > Unhandled Exception:
 System.TypeInitializationException: An exception>
 was thrown by the type initializer for>
 Mono.Debugger.Frontend.GnuReadLine --->
 System.DllNotFoundException:> libmonodebuggerreadlineYou
 must install the readline-devel RPM.Rob___Mono-devel-list
 mailing listMono-devel-list@lists.ximian.comhttp://lists.ximian.com/mailman/listinfo/mono-devel-list__This
 email has been scanned by the MessageLabs
 Email Security System.For more information
 please visit http://www.messagelabs.com/email
 __
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] error loading monodevelop

2005-07-12 Thread angarato surion

hi i have ubuntu 5.0.4
and im using xfce 4.2.2

when i rn monodevelop through terminal it shows this and it crashing








2005-07-12 13:36:32,813 [-1210233984] INFO 
MonoDevelop.Services.ILoggingService [(null)] - Reading 
/home/angaratosurion/.config/MonoDevelop/CodeCompletionData/mscorlib_1.0.5000.0_b77a5c561934e089.pidb
2005-07-12 13:36:32,986 [-1210233984] INFO 
MonoDevelop.Services.ILoggingService [(null)] - WARNING Could not find 
stock Icons.16x16.FindPrevIcon
2005-07-12 13:36:33,001 [-1210233984] INFO 
MonoDevelop.Services.ILoggingService [(null)] - WARNING Could not find 
stock gtk-stop
2005-07-12 13:36:33,049 [-1210233984] INFO 
MonoDevelop.Services.ILoggingService [(null)] - Creating DefaultWorkbench


(MonoDevelop:12859): Gtk-WARNING **: Theme file for crystalblue has no 
directories



(MonoDevelop:12859): Gtk-WARNING **: Theme file for crystalblue has no 
directories


2005-07-12 13:37:29,229 [-1210233984] INFO 
MonoDevelop.Services.ILoggingService [(null)] - WARNING Could not find 
stock gtk-open
2005-07-12 13:37:30,069 [-1241965648] INFO 
MonoDevelop.Services.ILoggingService [(null)] - Reading 
/media/win_d/Τα_Προγραμματά_μου/linux/Castoras/Castoras.pidb2005-07-12 
13:37:30,159 [-1241965648] INFO MonoDevelop.Services.ILoggingService 
[(null)] - Reading 
/home/angaratosurion/.config/MonoDevelop/CodeCompletionData/glib-sharp_1.0.0.0_35e10195dab3c99f.pidb
2005-07-12 13:37:30,181 [-1241965648] INFO 
MonoDevelop.Services.ILoggingService [(null)] - Reading 
/home/angaratosurion/.config/MonoDevelop/CodeCompletionData/System_1.0.5000.0_b77a5c561934e089.pidb
2005-07-12 13:37:30,256 [-1241965648] INFO 
MonoDevelop.Services.ILoggingService [(null)] - Reading 
/home/angaratosurion/.config/MonoDevelop/CodeCompletionData/System.Xml_1.0.5000.0_b77a5c561934e089.pidb
2005-07-12 13:37:30,420 [-1241965648] INFO 
MonoDevelop.Services.ILoggingService [(null)] - Reading 
/home/angaratosurion/.config/MonoDevelop/CodeCompletionData/gdk-sharp_1.0.0.0_35e10195dab3c99f.pidb
2005-07-12 13:37:30,471 [-1241965648] INFO 
MonoDevelop.Services.ILoggingService [(null)] - Reading 
/home/angaratosurion/.config/MonoDevelop/CodeCompletionData/pango-sharp_1.0.0.0_35e10195dab3c99f.pidb
2005-07-12 13:37:30,693 [-1210233984] INFO 
MonoDevelop.Services.ILoggingService [(null)] - WARNING Could not find 
stock gtk-save
2005-07-12 13:37:36,400 [-1244337232] INFO 
MonoDevelop.Services.ILoggingService [(null)] - Reading 
/home/angaratosurion/.config/MonoDevelop/CodeCompletionData/atk-sharp_1.0.0.0_35e10195dab3c99f.pidb


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-WARNING **: instance of invalid 
non-instantiatable type `glong'


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_signal_emit_valist: 
assertion `G_TYPE_CHECK_INSTANCE (instance)' failed


(MonoDevelop:12859): GLib-GObject-WARNING **: instance of invalid 
non-instantiatable type `GtkCellRendererText'


(MonoDevelop:12859): GLib-GObject-CRITICAL **: 
g_signal_handlers_destroy: assertion `G_TYPE_CHECK_INSTANCE (instance)' 
failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OBJECT (object)' failed


(MonoDevelop:12859): GLib-GObject-CRITICAL **: g_object_unref: assertion 
`G_IS_OB

Re: [Mono-devel-list] DateTime Parameters in MSSQL Server

2005-07-12 Thread Hubert FONGARNAND
Here's my patch to solve my problem :

I've added an other little modification :
With my patch it's possible (like MS.NET) to pass a byte array with a null 
length as a binary parameter.

Le Mardi 12 Juillet 2005 16:30, Hubert FONGARNAND a écrit :
> Le Mardi 12 Juillet 2005 15:50, Hubert FONGARNAND a écrit :
> I've found where is the problem
>
> Fri Jan 7 08:26:07 2005 suresh has submitted a patch wich change the format
> of datetime parameters from :
>  value = String.Format(System.Globalization.CultureInfo.InvariantCulture,
>'{0:MM/dd/ hh:mm:ss tt}'", d
> );
>
> to
> value = String.Format(System.Globalization.CultureInfo.InvariantCulture,
>"'{0:MMM dd  hh:mm:ss tt}'", d );
>
> i've restored the old line (0:MM/dd/ hh:mm:ss tt) and it works for me
> now! but I think this problems comes from the database culture...
>
> Is it possible that the Tds drivers could adapt it automatically to the
> database???
> I think, it's a very bad idea to change the mono code source each time you
> change your database...
>
>
> thanks
>
> > The problems comes from the method
> >
> > private string FormatParameter (TdsMetaParameter parameter)
> >
> > in Mono.Data.tds.protocol
> >
> > wich encode parameters in order to send them to SQL Server. With MS.NET,
> > parameters are send using a binary format, with mono, parameters are sent
> > using the "string" format...
> > It's a problem when dealing with dates :
> > case "datetime":
> >DateTime d = (DateTime)parameter.Value;
> > value =
> > String.Format(System.Globalization.CultureInfo.InvariantCulture,
> >   "'{0:MMM dd 
> > hh:mm:ss tt}'", d );
> > break;
> >
> > Is the format "MMM dd  hh:mm:ss tt" correct? for all SQL Server 2000
> > (french version)
> >
> > Le Mardi 12 Juillet 2005 15:42, Chris van Wyk a écrit :
> > > Hi,
> > >
> > > Datetime has also been giving me huge amounts of problems.
> > >
> > > The work around for me was to convert the item using ToString("s"). If
> > > you are going to use stored procs, you will need to modify your stored
> > > proc parameters in the sql statement to string in stead of datetime.
> > >
> > > I have also been able to get the Microsoft.ApplicationBlocks.Data going
> > > with modification to specific DateTime parameter formatting.
> > >
> > > There seems to be problems with the data adapter using the sqlhelper
> > > from the above. I am getting concurrency errors on updates for
> > > instance. If someone else has had concurrency errors please let me know
> > > as I have been able to work round this, but I'm not sure if it is a bug
> > > in Mono.
> > >
> > > I am using 1.1.7 and have not tested the above on 1.1.8
> > >
> > > Regards
> > > Chris
> > >
> > > > -Original Message-
> > > > From: [EMAIL PROTECTED]
> > > > [mailto:mono-devel-list- [EMAIL PROTECTED] On Behalf Of
> > > > Hubert FONGARNAND
> > > > Sent: 12 July 2005 03:28 PM
> > > > To: mono-devel-list@lists.ximian.com
> > > > Subject: [Mono-devel-list] DateTime Parameters in MSSQL Server
> > > >
> > > > I've an issue with datetime parameters with MSSQL Server in Mono...
> > > > It seem's that the parameters is badly sent to the SQL Server...
> > > > Please test that :
> > > >
> > > > using System;
> > > > using System.Data;
> > > > using System.Data.SqlClient;
> > > >
> > > > class MainClass
> > > > {
> > > > static string cnx="user id=sa;password=sa;data
> > > > source=10.69.100.93;initial
> > > > catalog=Fiche_Produit";
> > > >
> > > >
> > > > public static void Main(string[] args)
> > > > {
> > > > Console.WriteLine("Hello World!");
> > > > SqlCommand cmd=new SqlCommand();
> > > > cmd.Connection=new SqlConnection(cnx);
> > > > cmd.CommandText="INSERT INTO essais (date) VALUES 
> > > > (@date)";
> > > > cmd.Parameters.Clear();
> > > >
> > > > 
> > > > cmd.Parameters.Add("@date",SqlDbType.DateTime).Value=DateTime.Now;
> > > > cmd.Connection.Open();
> > > > cmd.ExecuteNonQuery();
> > > > cmd.Connection.Close();
> > > > }
> > > > }
> > > >
> > > > it returns :
> > > > Unhandled Exception: System.Data.SqlClient.SqlException: Erreur de
> > > > conversion
> > > > du type de données varchar en datetime.
> > > > Erreur de conversion du type de données varchar en datetime.
> > > > in [0x00034]
> > > > (at
> > > > /home/hubert/mono/mcs/class/System.Data/System.Data.SqlClient/SqlConn
> > > >ec ti o n.cs:266)
> > > > System.Data.SqlClient.SqlConnection:ErrorHandler (System.Object
> > > > sender, Mono.Data.Tds.Protocol.TdsInternalErrorMessageEventArgs e)
> > > > in (wrapper delegate-invoke)
> > > > System.MulticastDelegate:invoke_void_object_TdsInternalErrorMessageEv
> > > >en tA r gs
> > > > 

Re: [Mono-devel-list] DateTime Parameters in MSSQL Server

2005-07-12 Thread Hubert FONGARNAND
Le Mardi 12 Juillet 2005 15:50, Hubert FONGARNAND a écrit :
I've found where is the problem

Fri Jan 7 08:26:07 2005 suresh has submitted a patch wich change the format of 
datetime parameters from :
 value = String.Format(System.Globalization.CultureInfo.InvariantCulture,
   '{0:MM/dd/ hh:mm:ss tt}'", d );

to
value = String.Format(System.Globalization.CultureInfo.InvariantCulture,
 "'{0:MMM dd  hh:mm:ss tt}'", d );

i've restored the old line (0:MM/dd/ hh:mm:ss tt) and it works for me now!
but I think this problems comes from the database culture...

Is it possible that the Tds drivers could adapt it automatically to the 
database??? 
I think, it's a very bad idea to change the mono code source each time you 
change your database...


thanks
> The problems comes from the method
>
> private string FormatParameter (TdsMetaParameter parameter)
>
> in Mono.Data.tds.protocol
>
> wich encode parameters in order to send them to SQL Server. With MS.NET,
> parameters are send using a binary format, with mono, parameters are sent
> using the "string" format...
> It's a problem when dealing with dates :
> case "datetime":
>DateTime d = (DateTime)parameter.Value;
> value =
> String.Format(System.Globalization.CultureInfo.InvariantCulture,
>   "'{0:MMM dd 
> hh:mm:ss tt}'", d );
> break;
>
> Is the format "MMM dd  hh:mm:ss tt" correct? for all SQL Server 2000
> (french version)
>
> Le Mardi 12 Juillet 2005 15:42, Chris van Wyk a écrit :
> > Hi,
> >
> > Datetime has also been giving me huge amounts of problems.
> >
> > The work around for me was to convert the item using ToString("s"). If
> > you are going to use stored procs, you will need to modify your stored
> > proc parameters in the sql statement to string in stead of datetime.
> >
> > I have also been able to get the Microsoft.ApplicationBlocks.Data going
> > with modification to specific DateTime parameter formatting.
> >
> > There seems to be problems with the data adapter using the sqlhelper from
> > the above. I am getting concurrency errors on updates for instance. If
> > someone else has had concurrency errors please let me know as I have been
> > able to work round this, but I'm not sure if it is a bug in Mono.
> >
> > I am using 1.1.7 and have not tested the above on 1.1.8
> >
> > Regards
> > Chris
> >
> > > -Original Message-
> > > From: [EMAIL PROTECTED] [mailto:mono-devel-list-
> > > [EMAIL PROTECTED] On Behalf Of Hubert FONGARNAND
> > > Sent: 12 July 2005 03:28 PM
> > > To: mono-devel-list@lists.ximian.com
> > > Subject: [Mono-devel-list] DateTime Parameters in MSSQL Server
> > >
> > > I've an issue with datetime parameters with MSSQL Server in Mono...
> > > It seem's that the parameters is badly sent to the SQL Server...
> > > Please test that :
> > >
> > > using System;
> > > using System.Data;
> > > using System.Data.SqlClient;
> > >
> > > class MainClass
> > > {
> > >   static string cnx="user id=sa;password=sa;data
> > > source=10.69.100.93;initial
> > > catalog=Fiche_Produit";
> > >
> > >
> > >   public static void Main(string[] args)
> > >   {
> > >   Console.WriteLine("Hello World!");
> > >   SqlCommand cmd=new SqlCommand();
> > >   cmd.Connection=new SqlConnection(cnx);
> > >   cmd.CommandText="INSERT INTO essais (date) VALUES (@date)";
> > >   cmd.Parameters.Clear();
> > >
> > >   cmd.Parameters.Add("@date",SqlDbType.DateTime).Value=DateTime.Now;
> > >   cmd.Connection.Open();
> > >   cmd.ExecuteNonQuery();
> > >   cmd.Connection.Close();
> > >   }
> > > }
> > >
> > > it returns :
> > > Unhandled Exception: System.Data.SqlClient.SqlException: Erreur de
> > > conversion
> > > du type de données varchar en datetime.
> > > Erreur de conversion du type de données varchar en datetime.
> > > in [0x00034]
> > > (at
> > > /home/hubert/mono/mcs/class/System.Data/System.Data.SqlClient/SqlConnec
> > >ti o n.cs:266)
> > > System.Data.SqlClient.SqlConnection:ErrorHandler (System.Object sender,
> > > Mono.Data.Tds.Protocol.TdsInternalErrorMessageEventArgs e)
> > > in (wrapper delegate-invoke)
> > > System.MulticastDelegate:invoke_void_object_TdsInternalErrorMessageEven
> > >tA r gs
> > > (object,Mono.Data.Tds.Protocol.TdsInternalErrorMessageEventArgs)
> > >
> > >
> > > In english : error when converting a varchar datatype into a datetime
> > >
> > > thanks
> > >
> > > ___
> > > Ce message et les éventuels documents joints peuvent contenir des
> > > informations confidentielles.
> > > Au cas où il ne vous serait pas destiné, nous vous remercions de bien
> > > vouloir le supprimer et en aviser immédiatement l'expéditeur. Toute
> > > utilisation de ce message non conforme à sa destination, toute
> > > diffusion ou publicat

Re: [Mono-devel-list] DateTime Parameters in MSSQL Server

2005-07-12 Thread Hubert FONGARNAND
The problems comes from the method

private string FormatParameter (TdsMetaParameter parameter)

in Mono.Data.tds.protocol

wich encode parameters in order to send them to SQL Server. With MS.NET, 
parameters are send using a binary format, with mono, parameters are sent 
using the "string" format...
It's a problem when dealing with dates :
case "datetime":
   DateTime d = (DateTime)parameter.Value;
value = 
String.Format(System.Globalization.CultureInfo.InvariantCulture,
  "'{0:MMM dd  
hh:mm:ss tt}'", d );
break;

Is the format "MMM dd  hh:mm:ss tt" correct? for all SQL Server 2000 
(french version)

Le Mardi 12 Juillet 2005 15:42, Chris van Wyk a écrit :
> Hi,
>
> Datetime has also been giving me huge amounts of problems.
>
> The work around for me was to convert the item using ToString("s"). If you
> are going to use stored procs, you will need to modify your stored proc
> parameters in the sql statement to string in stead of datetime.
>
> I have also been able to get the Microsoft.ApplicationBlocks.Data going
> with modification to specific DateTime parameter formatting.
>
> There seems to be problems with the data adapter using the sqlhelper from
> the above. I am getting concurrency errors on updates for instance. If
> someone else has had concurrency errors please let me know as I have been
> able to work round this, but I'm not sure if it is a bug in Mono.
>
> I am using 1.1.7 and have not tested the above on 1.1.8
>
> Regards
> Chris
>
> > -Original Message-
> > From: [EMAIL PROTECTED] [mailto:mono-devel-list-
> > [EMAIL PROTECTED] On Behalf Of Hubert FONGARNAND
> > Sent: 12 July 2005 03:28 PM
> > To: mono-devel-list@lists.ximian.com
> > Subject: [Mono-devel-list] DateTime Parameters in MSSQL Server
> >
> > I've an issue with datetime parameters with MSSQL Server in Mono...
> > It seem's that the parameters is badly sent to the SQL Server...
> > Please test that :
> >
> > using System;
> > using System.Data;
> > using System.Data.SqlClient;
> >
> > class MainClass
> > {
> > static string cnx="user id=sa;password=sa;data
> > source=10.69.100.93;initial
> > catalog=Fiche_Produit";
> >
> >
> > public static void Main(string[] args)
> > {
> > Console.WriteLine("Hello World!");
> > SqlCommand cmd=new SqlCommand();
> > cmd.Connection=new SqlConnection(cnx);
> > cmd.CommandText="INSERT INTO essais (date) VALUES (@date)";
> > cmd.Parameters.Clear();
> >
> > cmd.Parameters.Add("@date",SqlDbType.DateTime).Value=DateTime.Now;
> > cmd.Connection.Open();
> > cmd.ExecuteNonQuery();
> > cmd.Connection.Close();
> > }
> > }
> >
> > it returns :
> > Unhandled Exception: System.Data.SqlClient.SqlException: Erreur de
> > conversion
> > du type de données varchar en datetime.
> > Erreur de conversion du type de données varchar en datetime.
> > in [0x00034]
> > (at
> > /home/hubert/mono/mcs/class/System.Data/System.Data.SqlClient/SqlConnecti
> >o n.cs:266)
> > System.Data.SqlClient.SqlConnection:ErrorHandler (System.Object sender,
> > Mono.Data.Tds.Protocol.TdsInternalErrorMessageEventArgs e)
> > in (wrapper delegate-invoke)
> > System.MulticastDelegate:invoke_void_object_TdsInternalErrorMessageEventA
> >r gs
> > (object,Mono.Data.Tds.Protocol.TdsInternalErrorMessageEventArgs)
> >
> >
> > In english : error when converting a varchar datatype into a datetime
> >
> > thanks
> >
> > ___
> > Ce message et les éventuels documents joints peuvent contenir des
> > informations confidentielles.
> > Au cas où il ne vous serait pas destiné, nous vous remercions de bien
> > vouloir le supprimer et en aviser immédiatement l'expéditeur. Toute
> > utilisation de ce message non conforme à sa destination, toute diffusion
> > ou publication, totale ou partielle et quel qu'en soit le moyen est
> > formellement interdite.
> > Les communications sur internet n'étant pas sécurisées, l'intégrité de ce
> > message n'est pas assurée et la société émettrice ne peut être tenue pour
> > responsable de son contenu.
> > ___
> > Mono-devel-list mailing list
> > Mono-devel-list@lists.ximian.com
> > http://lists.ximian.com/mailman/listinfo/mono-devel-list
>
> ___
> Mono-devel-list mailing list
> Mono-devel-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list

___
Ce message et les éventuels documents joints peuvent contenir des informations 
confidentielles.
Au cas où il ne vous serait pas destiné, nous vous remercions de bien vouloir 
le supprimer et en aviser immédiatement l'expéditeur. Toute utilisation de ce 
message non conforme à sa destination, toute diffusion ou publicati

RE: [Mono-devel-list] DateTime Parameters in MSSQL Server

2005-07-12 Thread Chris van Wyk
Hi,

Datetime has also been giving me huge amounts of problems. 

The work around for me was to convert the item using ToString("s"). If you
are going to use stored procs, you will need to modify your stored proc
parameters in the sql statement to string in stead of datetime.

I have also been able to get the Microsoft.ApplicationBlocks.Data going with
modification to specific DateTime parameter formatting.

There seems to be problems with the data adapter using the sqlhelper from
the above. I am getting concurrency errors on updates for instance. If
someone else has had concurrency errors please let me know as I have been
able to work round this, but I'm not sure if it is a bug in Mono.

I am using 1.1.7 and have not tested the above on 1.1.8

Regards
Chris


> -Original Message-
> From: [EMAIL PROTECTED] [mailto:mono-devel-list-
> [EMAIL PROTECTED] On Behalf Of Hubert FONGARNAND
> Sent: 12 July 2005 03:28 PM
> To: mono-devel-list@lists.ximian.com
> Subject: [Mono-devel-list] DateTime Parameters in MSSQL Server
> 
> I've an issue with datetime parameters with MSSQL Server in Mono...
> It seem's that the parameters is badly sent to the SQL Server...
> Please test that :
> 
> using System;
> using System.Data;
> using System.Data.SqlClient;
> 
> class MainClass
> {
>   static string cnx="user id=sa;password=sa;data
> source=10.69.100.93;initial
> catalog=Fiche_Produit";
> 
> 
>   public static void Main(string[] args)
>   {
>   Console.WriteLine("Hello World!");
>   SqlCommand cmd=new SqlCommand();
>   cmd.Connection=new SqlConnection(cnx);
>   cmd.CommandText="INSERT INTO essais (date) VALUES (@date)";
>   cmd.Parameters.Clear();
> 
>   cmd.Parameters.Add("@date",SqlDbType.DateTime).Value=DateTime.Now;
>   cmd.Connection.Open();
>   cmd.ExecuteNonQuery();
>   cmd.Connection.Close();
>   }
> }
> 
> it returns :
> Unhandled Exception: System.Data.SqlClient.SqlException: Erreur de
> conversion
> du type de données varchar en datetime.
> Erreur de conversion du type de données varchar en datetime.
> in [0x00034]
> (at
> /home/hubert/mono/mcs/class/System.Data/System.Data.SqlClient/SqlConnectio
> n.cs:266)
> System.Data.SqlClient.SqlConnection:ErrorHandler (System.Object sender,
> Mono.Data.Tds.Protocol.TdsInternalErrorMessageEventArgs e)
> in (wrapper delegate-invoke)
> System.MulticastDelegate:invoke_void_object_TdsInternalErrorMessageEventAr
> gs
> (object,Mono.Data.Tds.Protocol.TdsInternalErrorMessageEventArgs)
> 
> 
> In english : error when converting a varchar datatype into a datetime
> 
> thanks
> 
> ___
> Ce message et les éventuels documents joints peuvent contenir des
> informations confidentielles.
> Au cas où il ne vous serait pas destiné, nous vous remercions de bien
> vouloir le supprimer et en aviser immédiatement l'expéditeur. Toute
> utilisation de ce message non conforme à sa destination, toute diffusion
> ou publication, totale ou partielle et quel qu'en soit le moyen est
> formellement interdite.
> Les communications sur internet n'étant pas sécurisées, l'intégrité de ce
> message n'est pas assurée et la société émettrice ne peut être tenue pour
> responsable de son contenu.
> ___
> Mono-devel-list mailing list
> Mono-devel-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] DateTime Parameters in MSSQL Server

2005-07-12 Thread Hubert FONGARNAND
I've an issue with datetime parameters with MSSQL Server in Mono...
It seem's that the parameters is badly sent to the SQL Server...
Please test that :

using System;
using System.Data;
using System.Data.SqlClient;

class MainClass
{
static string cnx="user id=sa;password=sa;data 
source=10.69.100.93;initial 
catalog=Fiche_Produit";


public static void Main(string[] args)
{
Console.WriteLine("Hello World!");
SqlCommand cmd=new SqlCommand();
cmd.Connection=new SqlConnection(cnx);
cmd.CommandText="INSERT INTO essais (date) VALUES (@date)";
cmd.Parameters.Clear();

cmd.Parameters.Add("@date",SqlDbType.DateTime).Value=DateTime.Now;
cmd.Connection.Open();
cmd.ExecuteNonQuery();
cmd.Connection.Close();
}
}

it returns :
Unhandled Exception: System.Data.SqlClient.SqlException: Erreur de conversion 
du type de données varchar en datetime.
Erreur de conversion du type de données varchar en datetime.
in [0x00034] 
(at 
/home/hubert/mono/mcs/class/System.Data/System.Data.SqlClient/SqlConnection.cs:266)
 
System.Data.SqlClient.SqlConnection:ErrorHandler (System.Object sender, 
Mono.Data.Tds.Protocol.TdsInternalErrorMessageEventArgs e)
in (wrapper delegate-invoke) 
System.MulticastDelegate:invoke_void_object_TdsInternalErrorMessageEventArgs 
(object,Mono.Data.Tds.Protocol.TdsInternalErrorMessageEventArgs)


In english : error when converting a varchar datatype into a datetime

thanks

___
Ce message et les éventuels documents joints peuvent contenir des informations 
confidentielles.
Au cas où il ne vous serait pas destiné, nous vous remercions de bien vouloir 
le supprimer et en aviser immédiatement l'expéditeur. Toute utilisation de ce 
message non conforme à sa destination, toute diffusion ou publication, totale 
ou partielle et quel qu'en soit le moyen est formellement interdite.
Les communications sur internet n'étant pas sécurisées, l'intégrité de ce 
message n'est pas assurée et la société émettrice ne peut être tenue pour 
responsable de son contenu.
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list