locale problem...

Scott C. Gray gray at voicenet.com
Wed Aug 23 07:31:28 EDT 2000


On Wed, 23 Aug 2000, Mac Wang wrote:

> I am doing a project about my school library, they use sybase ASE 11.x.
> When I use the open client under windows, I can get chinese word correctly
> (after setting up the locale.dat)...
> But when I use PHP under linux to get some Chinese column, it said..
> 
> Sybase message:  WARNING!  Some character(s) could not be converted into
> client's character set.
> Unconverted bytes were changed to question marks ('?').
> 
> Could anybody tell me how can I set locale information under linux using
> freetds with PHP??
> thank you very much...

There is no direct support in freetds for changing/setting charset
or any other locale information from the ctlib library. However,
if you feel like recompiling your CT-Lib PHP module, you can add
the line 

     tds_set_charset(conn->tds_login, "???");

where conn is your CS_CONNECTION and ??? is the name of the charset
that you want the server to use. This may do what you want.

-scott

--
Scott C. Gray <gray at voicenet.com>     "my keybard is brken"
       http://www.voicenet.com/~gray/sqsh.html




More information about the FreeTDS mailing list