From: Ian B. <ia...@co...> - 2004-12-07 17:35:56
|
I was going to add a FAQ entry about unicode, but then it had a bunch of code, and I figured I should just include the code. Now there is a UnicodeCol, mostly the same as what Oleg described before. This doesn't solve the query issue, since queries involving unicode will fail currently. There's a couple ways to do that: * Process-global encodings, added to sqlobject.converters * If we move to database parameters instead of building SQL textually, we could do per-database default encodings. The dbconnection instance would loop through the parameters and convert any unicode strings it found. * sqlbuilder.SQLObjectField could pay attention to encoding. Actually, I want to get rid of the .q stuff, and just make cls.column into a descriptor, so that when fetched from a class it's an object that can be used in a query. But either way this is fairly doable. -- Ian Bicking / ia...@co... / http://blog.ianbicking.org |