Skip to Content.
Sympa Menu

freetds - Re: [freetds] UTF-8 issue

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: Frediano Ziglio <freddy77 AT gmail.com>
  • To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] UTF-8 issue
  • Date: Wed, 9 Jan 2019 13:26:51 +0000

Hi,
CP1252 is available like many other encoding, but trying to use
cp1252 and Japanese will just create garbage, FreeTDS is just warning
you, if you want garbage in the database the configuration is fine but
probably is not what you want.
How is data stored into the database? Which collation is the database?
Which type and collation are the columns supposed to contain Japanese?
Which encoding are you using on the client. The "Client Charset"
should respect this and will be use for "ANSI" function (the not wide
ones, wide in UnixODBC means UTF-16 like Windows).

Regards,
Frediano

Il giorno mer 9 gen 2019 alle ore 06:52 Deepa Umesh
<Deepa.Umesh AT aptean.com> ha scritto:
>
> Hi Peter,
>
> Let me summarize my installation and configuration settings :
>
> We are using FreeTDS(freetds-1.00.99) with UnixODBC(unixODBC-2.2.13) in
> Linux Platform and provided the following configuration in
> Odbc.ini in UnicODBC is as below:
>
> [sqlprog1]
> Driver=/usr/local/freetds-1.00.97/lib/libtdsodbc.so
> Server=172.16.127.134
> Database=sqlprog1_catdev19
> Port=1433
> TDS_Version=7.3
> Client Charset = CP1252
>
> CP1252 is used in Windows Platform , is there anything similar to CP1252 in
> Linux?
>
> Thanks,
> Deepa
>
> -----Original Message-----
> From: FreeTDS <freetds-bounces AT lists.ibiblio.org> On Behalf Of Peter Deacon
> Sent: Tuesday, January 8, 2019 10:58 PM
> To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
> Subject: Re: [freetds] UTF-8 issue
>
> On Tue, 8 Jan 2019, Deepa Umesh wrote:
>
> > Hi Peter,
> > I set ClientCharset=CP1252 in odbc.ini (unixODBC) But the result is as
> > previous :
>
> > [FreeTDS][SQL Server]Some character(s) could not be converted into
> > client's character set. Unconverted bytes were changed to question
> > marks ('?')
>
> Hi Deepa,
>
> Normally this encoding causes everything to be mapped across so above would
> not occur. Recommend checking FreeTDS logs to confirm this is actually
> encoding used by FreeTDS.
>
> Also make sure FreeTDS uses libiconv when compiling.
>
> regards,
> Peter
>
> > So do I need to reinstall freetds with this configuration in freetds.conf
> > ?
>
>
> > Request you to provide additional info on installation stuff.
> > Also is there any config flags to be set?
> >
> > Thanks,
> > Deepa
> >
> > -----Original Message-----
> > From: FreeTDS <freetds-bounces AT lists.ibiblio.org> On Behalf Of Peter
> > Deacon
> > Sent: Tuesday, January 8, 2019 1:50 PM
> > To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
> > Subject: Re: [freetds] UTF-8 issue
> >
> > On Tue, 8 Jan 2019, Deepa Umesh wrote:
> >
> >> Hi ,
> >> I am trying to rephrase my question with more clarity,
> >
> >> We are using UTF-8 as encoding in our product, which uses single byte
> >> of character data, But when we attempt to use non US ASCII UTF-8
> >> charecters , we are having encoding problems similar to the
> >> following,
> >
> >> Insert query : insert into altitem values ('あなたの犬を散歩したいと思います');
> >
> >> [FreeTDS][SQL Server]Some character(s) could not be converted into
> >> client's character set. Unconverted bytes were changed to question
> >> marks ('?')
> >
> >>> [sqlprog1]
> >>> Driver=/usr/local/freetds-1.00.97/lib/libtdsodbc.so
> >>> Server=172.16.127.134
> >>> Database=sqlprog1_catdev19
> >>> Port=1433
> >>> TDS_Version=7.3
> >>> Client Charset = UTF-8.
> >
> > Hi Deepa,
> >
> > Set ClientCharset=CP1252
> >
> > regards,
> > Peter
> > _______________________________________________
> > FreeTDS mailing list
> > FreeTDS AT lists.ibiblio.org
> > https://lists.ibiblio.org/mailman/listinfo/freetds
> > This message contains information that is confidential and/or may be
> > privileged. If you are not the intended recipient, you are hereby
> > notified that any use, dissemination, distribution or copy of this
> > message and/or its attachments is strictly prohibited. If you have
> > received this message in error, please advise the sender immediately
> > by replying to this email and delete this message. We are committed to
> > your privacy. For more information, please see our Privacy Policy at
> > http://www.aptean.com/privacy-statement
> > _______________________________________________
> > FreeTDS mailing list
> > FreeTDS AT lists.ibiblio.org
> > https://lists.ibiblio.org/mailman/listinfo/freetds
> >
> _______________________________________________
> FreeTDS mailing list
> FreeTDS AT lists.ibiblio.org
> https://lists.ibiblio.org/mailman/listinfo/freetds
> This message contains information that is confidential and/or may be
> privileged. If you are not the intended recipient, you are hereby notified
> that any use, dissemination, distribution or copy of this message and/or
> its attachments is strictly prohibited. If you have received this message
> in error, please advise the sender immediately by replying to this email
> and delete this message. We are committed to your privacy. For more
> information, please see our Privacy Policy at
> http://www.aptean.com/privacy-statement
> _______________________________________________
> FreeTDS mailing list
> FreeTDS AT lists.ibiblio.org
> https://lists.ibiblio.org/mailman/listinfo/freetds




Archive powered by MHonArc 2.6.24.

Top of Page