freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
- From: "James K. Lowden" <jklowden AT freetds.org>
- To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
- Subject: Re: [freetds] Status of UTF-8 support in 0.83 dev
- Date: Thu, 14 Aug 2008 10:46:01 -0400
Sebastien FLAESCH wrote:
> From my understanding, if on Windows you write a "UNICODE" UCS-2 ODBC
> application using wchar_t/WCHAR, you have to bind using:
>
> SQL_C_WCHAR + SQL_W[VAR]CHAR
>
> But what about UTF-8 ODBC applications in FreeTDS?
>
> Does FreeTDS ODBC consider that UTF-8 is an equivalent for the Microsoft
> "UNICODE" and therefore must be bound with SQL_C_CHAR + SQL_W[VAR]CHAR?
>
> IBM DB2 CLI says UTF-8 data can be bound with SQL_[VAR]CHAR
I agree with IBM.
"Wide" characters have a fixed width, usually 16 bits. UTF-8 has a
variable width and for the most part can be treated like ASCII (strlen(3)
et al.). Declaring UTF-8 as SQL_C_WCHAR incorrectly tells the driver
there's a character in every two bytes.
--jkl
-
Re: [freetds] Status of UTF-8 support in 0.83 dev
, (continued)
-
Re: [freetds] Status of UTF-8 support in 0.83 dev,
Sebastien FLAESCH, 08/12/2008
-
Re: [freetds] Status of UTF-8 support in 0.83 dev,
James K. Lowden, 08/13/2008
-
Re: [freetds] Status of UTF-8 support in 0.83 dev,
Sebastien FLAESCH, 08/13/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, Sebastien FLAESCH, 08/14/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, James K. Lowden, 08/14/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, Sebastien FLAESCH, 08/14/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, James K. Lowden, 08/14/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, Sebastien FLAESCH, 08/14/2008
-
Re: [freetds] Status of UTF-8 support in 0.83 dev,
Sebastien FLAESCH, 08/13/2008
-
Re: [freetds] Status of UTF-8 support in 0.83 dev,
James K. Lowden, 08/13/2008
-
Re: [freetds] Status of UTF-8 support in 0.83 dev,
Sebastien FLAESCH, 08/12/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, Sebastien FLAESCH, 08/14/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, Sebastien FLAESCH, 08/14/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, James K. Lowden, 08/14/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, Sebastien FLAESCH, 08/14/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, James K. Lowden, 08/14/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, Frediano Ziglio, 08/17/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, James K. Lowden, 08/18/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, ZIGLIO, Frediano, VF-IT, 08/19/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, James K. Lowden, 08/19/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, James K. Lowden, 08/14/2008
- Re: [freetds] Status of UTF-8 support in 0.83 dev, Sebastien FLAESCH, 08/14/2008
Archive powered by MHonArc 2.6.24.