[unixODBC-dev] UNICODE and unixODBC
nick at lurcher.org
Sun Sep 4 21:23:27 BST 2005
Igor Korot wrote:
>So, do you think that if I install iODBC, than everything will be solved,and I won't have those errors?
>Also, if you try to install those packets together you would get these errors... I just don't get it. They are not using those types, yet the error messages report inconsistent types with SQLTCHAR. Could you clarify? Does that mean that SQLTCHAR is used by unixODBC? In this case the simple #define should take care of this issue...
Maybe, I don't know, You may avoid itwithiODBC if it ignores unicode,
it did in older versions but Ithink ithas support now.
SQLTCHARis a ODBC type, on windows if UNICODE is defined it becomes a
SQLWCHAR (short), and if its not defined a SQLCHAR (unsigned char), the
idea is that you can write code that works for UNICODE or not. If
UNICODE is defined all the ODBCAPI calls are defined as their W versions.
What I think wxGTK is doing is using SQLTCHAR, but expecting it to be
the same type as they are using for their unicode storage,I would guess
this is a short on windows, but fails on unix as it resolves to 32bit.
I would have said what wx should do is convert from ODBC unicode to
their representation if needed.
You CAN build unixODBC with 32bit unicode, you rebuild with
SQL_WCHART_CONVERT defined. But you then need a driver that supports
32bit chars, You will get away with it if you are just using a ansi
driver, as the driver manager will do the conversion.
I guess it depends on what driver you are using, and why you want to use
More information about the unixODBC-dev