Skip to Content.
Sympa Menu

freetds - RE: MS SQLServer 2000 and "for xml auto" command

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: ZIGLIO Frediano <Frediano.Ziglio AT vodafoneomnitel.it>
  • To: "'TDS Development Group'" <freetds AT franklin.metalab.unc.edu>
  • Subject: RE: MS SQLServer 2000 and "for xml auto" command
  • Date: Fri, 30 Aug 2002 11:31:08 +0200


> > This is true. But is not the same question...
> > I don't like de-unicoding data. Data may lost... as I
> suggest in a previous
> > mail late conversion is better.
> > If I write (in mssql7+) a column name in chinese (well, I
> don't still know
> > chinese..) there is no way to simply extract only this
> field from table (for
> > example) in our current implementation...
>
> I think UTF-8 is the way forward on this. The basic problem
> is what do
> the unix apps support? It sure isn't UCS-2. If they support unicode
> at all it's utf-8 and ucs-2 to utf-8 can be done losslessly.
> And then
> there are crippled clients that need single byte char sets, I
> can't see
> removing this for some years to come.
>

The problem with utf8 is that conversion from ucs2 -> utf8 require at max 3
bytes per 2 bytes. So if I return a nchar(8000) we should allocate 12000
bytes to store this type. If we store just ucs2 coding we can allocate only
8000 bytes. Another solution should use variable buffer for nchar/nvarchar,
calculate required uft8 length and than convert...
Samba solution is to use always utf8 coding for internal strings...

...
> > >
> > > I just need to know what I should do with the tds_convert_ntext()
> > > function....
>
> tds_convert_ntext should in theory be exactly like tds_convert_text.
>

unixODBC have function to support wide character (I suppose they use ucs2).
I know that gnome2 and kde3 support unicode much better than before. What
coding they use for unicode? utf8 (usually unix), ucs2 (windows) or
ucs4/utf4 (c wide char in linux) ?

...
>
> Brian
>
freddy77

=================================
"STRICTLY PERSONAL AND CONFIDENTIAL

This message may contain confidential and proprietary material for the sole
use of the intended recipient. Any review or distribution by others is
strictly prohibited. If you are not the intended recipient please contact
the sender and delete all copies.
The contents of this message that do not relate to the official business of
our company shall be understood as neither given nor endorsed by it."

=================================




Archive powered by MHonArc 2.6.24.

Top of Page