Unicode support in iODBC and UnixODBC -
07-18-2003
, 06:25 AM
I'm trying to get an idea of what text encodings iODBC and UnixODBC use
and whether there is a way of storing and retrieving Unicode text. I
have read the very limited documentation for these and even had a look
through the source code, but still don't have clear answers.
The "Unicode" API of UnixODBC appears to be a kluge that converts from
UCS-2 to ISO 8859-1 or ASCII (and doesn't necessarily do that correctly)
so that's out of the question.
Is it safe to use UTF-8 in SQLCHAR strings with these implementations of
ODBC? How do they communicate to their drivers which encoding is being
used - or do they just assume the application and database are configured
to use the same encoding? Is it possible to use UTF-16 or UTF-32 with
either of them? |