Skip to Content.
Sympa Menu

freetds - [freetds] [ freetds-Patches-3298035 ] Expose client charset as an odbc connection parameter

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "SourceForge.net" <noreply AT sourceforge.net>
  • To: noreply AT sourceforge.net
  • Subject: [freetds] [ freetds-Patches-3298035 ] Expose client charset as an odbc connection parameter
  • Date: Sat, 7 May 2011 20:14:30 +0200

Patches item #3298035, was opened at 2011-05-05 21:35
Message generated for change (Comment added) made by freddy77
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=407808&aid=3298035&group_id=33106

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
>Status: Closed
>Resolution: Out of Date
Priority: 5
Private: No
Submitted By: Brian Hawthorne ()
Assigned to: Nobody/Anonymous (nobody)
Summary: Expose client charset as an odbc connection parameter

Initial Comment:
We would like to develop against some mssql dbs from an ubuntu linux
environment, but had a very hard time configuring unixodbc/freetds to
acknowledge the freetds.conf file, which is the only way to configure client
charset, which is necessary for proper unicode support. The packaged ubuntu
unixodbc and freetds binaries are configured by default with unixodbc as the
driving configurator for freetds. So rather than bending over backwards to
set things up in a way that they don't want to be set up, I made a very small
patch to expose the client charset configuration as an odbc connection
parameter. Seems like you would want it to be anyway.

This patch is made against freetds-0.82.1.dev.20110409. I added the
following four lines after line 175 in src/odbc/connectparams.c:

tmp[0] = '\0';


if (SQLGetPrivateProfileString(DSN, "Client_Charset", "", tmp,
FILENAME_MAX, "odbc.ini") > 0) {

tds_dstr_copy(&connection->client_charset, tmp);


}

Now you can put Client_Charset=UTF-8 in your odbc.ini or your connect string.


----------------------------------------------------------------------

>Comment By: Frediano Ziglio (freddy77)
Date: 2011-05-07 20:14

Message:
Hi Brian. Your feature is already in 0.91 (still in RC) so I won't add to a
old release. The new parameter is "ClientCharset".


----------------------------------------------------------------------

Comment By: Brian Hawthorne ()
Date: 2011-05-05 21:37

Message:
Looks like sourceforge didn't pick up my name from the google login. I'm
Brian Hawthorne, email hawthorne at amyris dot com.

----------------------------------------------------------------------

You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=407808&aid=3298035&group_id=33106




Archive powered by MHonArc 2.6.24.

Top of Page