Neoview ODBC Drivers Manual (R2.5)

3 HP Neoview Unicode Driver for Windows
The HP Neoview Unicode driver allows an application to provide and retrieve Unicode data
using an ODBC interface for access to the Neoview database. The driver translates as necessary
between the client character set (locale) and the character encoding in the database.
Applications that are not Unicode-enabled also work with Unicode driver. In such cases, the
Unicode driver provides functionality identical to that of the 32–bit ANSI driver described in
Chapter 1 (page 15).
NOTE: Once an application has used either a Unicode or an ANSI API, it is committed to
continue in that mode. Subsequently invoking the other API type results in an error. You cannot
mix Unicode and ANSI APIs in one application.
When handling a wide character buffer, the Unicode driver supports client locales recognized
by the Microsoft ODBC driver manager. When handling a character buffer (as distinct from a
wide character buffer), the Unicode driver supports any of the following client locales:
English (ISO88591)
Japanese (MS932)
Western European (Latin-1)
Chinese (GB2)
For more information about character and wide character types in Unicode, see “Unicode C and
SQL Data Types” (page 48).
For general information about Unicode and Unicode data types, see the Microsoft Developer
Network Online Library at http://msdn.microsoft.com/en-us/library/ms709439(VS.85).aspx.
The Neoview platform supports any of the following character-set configurations:
ISO88591
SJIS
Unicode
The format in which a data item is encoded in the Neoview SQL database depends on several
factors: the client locale (for example, Chinese), the data type of the client buffer (for example
SQL_C_CHAR), the data type of the database column (for example NCHAR VARYING), and
the underlying character-set configuration (for example Unicode). This encoding should be
transparent to the application.
For comprehensive information about international character sets on Neoview, please consult
the HP Neoview Character Sets Administrator's Guide.
Drivers Supported
Unicode support is available in the 32–bit ODBC driver for Windows, the 64–bit driver for
Windows, and all supported ODBC drivers for UNIX.
Unicode APIs
Unicode-enabled applications connect to data sources, assign storage for data, and exchange
data with the Unicode driver (and so with the Neoview database) using Unicode versions of
Microsoft ODBC API functions, as described in the Microsoft Developer Network Online Library
at http://msdn.microsoft.com/en-us/library/ms709439(VS.85).aspx.
To provide support for Unicode-enabled applications, the ODBC Driver Manager and
SQLUCODE.H header file define Unicode-specific versions of functions that accept pointers to
character strings or the keyword SQLPOINTER among their arguments. The Unicode version
Drivers Supported 47