Sample Header Ad - 728x90

supplementary characters in FreeTDS

4 votes
1 answer
1405 views
I have a C++ application that connects to SQL Server 2008 through FreeTDS unixODBC on an RHEL box. However, i am unable to insert supplementary characters to the database through FreeTDS unixODBC. [FreeTDS][SQL Server]Error converting characters into server's character set. Some character(s) could not be converted This is the query that my application is hitting INSERT INTO mytable (SAMPLE) VALUES(N'乕乭𠁄𠁉乺丕') == version details == unixODBC version - 2.3.0 freeTDS version - 0.95 I can successfully insert the characters in BMP. This characters are inserted perfectly fine. INSERT INTO mytable (SAMPLE) VALUES(N'乕乭乺丕') While using Microsoft SQL Server Native Client for Linux, the supplementary characters are inserted properly. == freetds conf == [mysever.mydomain.com] host = mysever.mydomain.com port = 1433 tds version = 7.3 debug flags = 0xffff dump file = /tmp/dump.log dump file append = no client charset = UTF-16 use utf-16 = yes unixODBC v2.3.0 has been built with ./configure --prefix=/usr/local/ --enable-iconv --with-iconv-char-enc=UTF8 --with-iconv-ucode-enc=UTF16LE FreeTDS v0.95 has been built with ./configure --prefix=/usr/local --sysconfdir=/usr/local/etc --with-tdsver=7.3
Asked by D3XT3R (83 rep)
Feb 27, 2016, 03:04 PM
Last activity: Jan 14, 2017, 04:03 PM