freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
Re: [freetds] Problem of unicode ( non-english character )
- From: Frediano Ziglio <freddyz77 AT tin.it>
- To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
- Subject: Re: [freetds] Problem of unicode ( non-english character )
- Date: Sat, 27 Mar 2004 08:37:23 +0100
Il sab, 2004-03-27 alle 07:05, edwardspl AT ita.org.mo ha scritto:
> "Lowden, James K" wrote:
>
> > FreeTDS will use your system's iconv library to convert your clients'
> > encoding to/from the form of Unicode used by the server. All you need to
> > do is make sure FreeTDS uses the system's iconv, and specify the client
> > charset you want.
> >
> > 1. Make sure libiconv is installed.
>
> How can I sure libiconv is installed ?
>
During configure you should see something like
checking for iconv... yes
checking for iconv declaration...
extern size_t iconv (iconv_t cd, char * *inbuf, size_t
*inbytesleft, char * *outbuf, size_t *outbytesleft);
> > 2. Make sure FreeTDS detects you iconv library when you run ./configure.
> > Use "./configure --with-libiconv-prefix=" if need be.
> > 3. Use "iconv -l" to list your iconv's available encodings.
> > 4. Decide which encoding your client will use. I recommend UTF-8, if it
> > suits you.
>
> Does UTF-8 support the function of ( convert the charset of unicode )
> including multi-language ( english and non-english ( eg : chinese ) ) ?
>
UTF-8 do not convert anything. UTF-8 it's a charset. FreeTDS converts
all input to server charset and all server charset (unicode and
no-unicode) to your client charset. mssql uses UCS-2 for encoding. UTF-8
can represent all characters of UCS-2 so any character from server can
be converted to UTF-8.
> > 5. Add this line to the [global] section in your freetds.conf:
> > client charset = UTF-8
> > (or whatever encoding you choose).
> > 6. Test with tsql. If it doesn't work "export TDSDUMP=/tmp/tdsdump",
> > run tsql again, and look at the log. It will tell you if iconv was
> > engaged correctly. If it's not clear, send the log here.
>
> Sorry, how to test with tsql ?
> Just type "export TDSDUMP=/tmp/tdsdump" under Linux System ( shell prompt )
> ?
>
With "export TDSDUMP=/tmp/tdsdump" you set an environment variable, when
you execute tsql tsql detect this variable and write a dump of what is
doing. "export TDSDUMP=/tmp/tdsdump" is the standard shell syntax, if
you are using another shell (csh for example) refer to your man.
> > UTF-8 can encode all known writing systems, both real and fictional.
> > This of course includes English and Chinese.
>
> Sorry, don't quite understand the function ( useful ) of UTF-8...
>
- UTF-8 can represent ALL known characters (even characters not
supported by mssql and Windows)
- UTF-8 is ascii compatible
- UTF-8 has been well tested with FreeTDS
- UTF-8 is the standard representation of XML (and MUST be supported by
all XML implementations)
- all "recent" browser (surely 2/3 years old) support UTF-8 natively
- newer *nix support UTF-8 by default (ie RH Linux from version 8)
> Acutally, many thank for your help !
>
> Edward.
>
bye
freddy77
-
Re: [freetds] Problem of unicode ( non-english character )
, (continued)
- Re: [freetds] Problem of unicode ( non-english character ), edwardspl, 03/25/2004
-
RE: [freetds] Problem of unicode ( non-english character ),
Lowden, James K, 03/25/2004
-
Re: [freetds] Problem of unicode ( non-english character ),
edwardspl, 03/25/2004
-
Re: [freetds] Problem of unicode ( non-english character ),
James K. Lowden, 03/25/2004
- Re: [freetds] Problem of unicode ( non-english character ), edwardspl, 03/26/2004
-
Re: [freetds] Problem of unicode ( non-english character ),
James K. Lowden, 03/25/2004
-
Re: [freetds] Problem of unicode ( non-english character ),
edwardspl, 03/26/2004
- Re: [freetds] Problem of unicode ( non-english character ), Daniel Fazekas, 03/26/2004
- [freetds] Segmentation fault with Apache 2.0.49 and PHP 5.0.0b4 - FreeTDS 0.60, Carlo Simeone, 03/26/2004
-
Re: [freetds] Problem of unicode ( non-english character ),
edwardspl, 03/25/2004
-
RE: [freetds] Problem of unicode ( non-english character ),
Lowden, James K, 03/26/2004
-
Re: [freetds] Problem of unicode ( non-english character ),
edwardspl, 03/27/2004
- Re: [freetds] Problem of unicode ( non-english character ), Frediano Ziglio, 03/27/2004
-
Re: [freetds] Problem of unicode ( non-english character ),
James K. Lowden, 03/27/2004
-
Re: [freetds] Problem of unicode ( non-english character ),
edwardspl, 03/27/2004
-
Re: [freetds] Problem of unicode ( non-english character ),
James K. Lowden, 03/27/2004
-
[freetds] Problem of unicode ( Inserted data / Query ),
edwardspl, 03/29/2004
- [freetds] Re: Problem of unicode ( Inserted data / Query ), Daniel Fazekas, 03/29/2004
-
[freetds] Problem of unicode ( Inserted data / Query ),
edwardspl, 03/29/2004
-
Re: [freetds] Problem of unicode ( non-english character ),
James K. Lowden, 03/27/2004
-
Re: [freetds] Problem of unicode ( non-english character ),
edwardspl, 03/27/2004
-
Re: [freetds] Problem of unicode ( non-english character ),
edwardspl, 03/27/2004
Archive powered by MHonArc 2.6.24.