On 1/3/06, Max Ischenko <[EMAIL PROTECTED]> wrote:
> --- database.py (revision 411)
> +++ database.py (working copy)
> @@ -33,6 +33,8 @@
> # and the cache causes problems with sqlite.
> if self.uri.startswith("sqlite"):
> TheURIOpener.cachedURIs = {}
> + if self.uri.startswith("mysql"):
> + conn.query('SET NAMES utf8')
> self.threadingLocal.connection = conn
> return self.begin(conn)
>
> But what's next?
>
> Should I file a ticket? Generalize the patch to allow 'db client
> encoding' specified in the TG configuration files (that would result in
> SET NAMES or other command for corresponding database)? File a bug
> report to sqlobject?
>
> Am I completely wrong dealing with this issue?
That's certainly not general enough to go into a framework (not
everyone will use UTF8). I'd suggest posting on the sqlobject list to
see what they think. (Something like an additional parameter to the
mysqlconnection seems ideal, since this is a mysql-specific issue)
Kevin
--
Kevin Dangoor
Author of the Zesty News RSS newsreader
email: [EMAIL PROTECTED]
company: http://www.BlazingThings.com
blog: http://www.BlueSkyOnMars.com