[Mono-devel-list] Error converting datetime to string

Jurandy Martins Soares Junior jurandy at lsd.ic.unicamp.br
Thu Nov 4 12:14:21 EST 2004


Hi,

I'm developing an application with Mono/XSP, and using Postgresql as a 
database. I've worked with Npgsql.

Well, it's worked fine til I decided to play a little with datestyle. After 
the first try, the system crashed showing the message below.

To be straight, before  the sql command was ( 1) "SELECT * FROM junta", then 
I've changed it to ( 2) "SET DateStyle TO european; SELECT * FROM junta". 

Maybe it's a newbie question, but what is easiest way to play with datestyle?

Regards,
Jurandy Martins
-----------------------------------------------------------------------------
Server error in '/mono' application
Description: Error processing request.

Error Message: HTTP 500.

Stack Trace:

System.FormatException: Invalid format.
in [0x00055] (at /cvs/1-mono/mcs/class/corlib/System/DateTime.cs:1314) 
System.DateTime:ParseExact 
(string,string[],System.IFormatProvider,System.Globalization.DateTimeStyles)
in [0x00133] 
(at /cvs/1-mono/mcs/class/Npgsql/NpgsqlTypes/NpgsqlTypesHelper.cs:313) 
NpgsqlTypes.NpgsqlTypesHelper:ConvertBackendStringToSystemType 
(System.Collections.Hashtable,string,int,int)




More information about the Mono-devel-list mailing list