Oleg Broytmann wrote:
On Wed, Apr 26, 2006 at 12:38:39PM +0200, Robert Szefler wrote:
SQLobject *expects* UTF-8
SQLobject does not expect UTF-8. Probably you mean a default for
UnicodeCol, but you can change the default.
Yeah, I misrepresented the facts. The problem is given the default utf8
behavior and correct data and table/database definitions (wrt
encoding/collation) on the MySQL side the communication is still
dependent on some hidden defaults like my.cnf and/or compile-time
options and will fail if encoding is set to something different than
utf8. That is bad IMHO. This can be said to be MySQL's (libmysql's)
fault, but if it can be fixed by hardcoding the connection encoding, why
doesn't it?
cursor.execute('SET NAMES utf8') # ADDED
You can set the encoding in .my.cnf. Thus you don't need to patch
SQLObject.
I want SQLObject's (which is a high-level interface) behavior to be
deterministic and not dependent on site configuration. Again, if it can
be, why won't it? Can't we just fix the f*d up behavior?
We're actually using SQLObject in a commercial project right now and
this patch goes in. This just has to be done on the database driver
side. If it doesn't, every client code will have to take care of it.
-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
sqlobject-discuss mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sqlobject-discuss