http://bugzilla.novell.com/show_bug.cgi?id=434772

User [email protected] added comment
http://bugzilla.novell.com/show_bug.cgi?id=434772#c5


Jeff Williams <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[email protected]
                   |                            |m




--- Comment #5 from Jeff Williams <[email protected]>  2009-09-04 
10:28:55 MDT ---
I ran GDB on OpenSim w/ our Linux ODBC driver and found it was erroring out on
line 405 in OdbcConnection.cs. This in turn was traced back to the SQLConnect
DllImport in libodbc.cs. As Gert suspected, the only changes that occurred with
this DllImport (as well as all of the others for all ODBC functions) between
Mono 1.9.1 and Mono 2.x were the Unicode additions.

After I did some digging I had a hunch that one of the character sets wasn't
lining up now that Unicode was being used. I realized then that Mono, by
implementing Windows Unicode functions, uses UCS-2/UTF-16 and returns data in
that format. However the data being sent to/from these functions was malformed
because in our case Informix by default uses UCS-4 as its locale.

Thus the problem was fixed by merely changing /etc/unixODBC/odbc.ini (or
whichever INI you are using and setting the $ODBCINI param to it) to have the
following addition:

[ODBC]
UNICODE=UCS-2

To instruct Informix to send and receive data over its ODBC driver in UCS-2.

I'm not sure if all Linux ODBC drivers support UCS-2 as the default on most
Linux distros I believe is UTF-8. Although Gert said MySQL was working
correctly I am not sure what configuration he is using and haven't tested it. 

>From what I can tell, it would appear that Mono requires the ODBC driver to
support UCS-2 to work properly and to be configured as such.

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
_______________________________________________
mono-bugs maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-bugs

Reply via email to