As emocionantes aventuras de um sysadmin linux na procura pelo uptime perfeito!

Turbogears, Mysql and UTF. Advice Needed!

Posted: novembro 16th, 2006 | Author: coredump | Filed under: Programação | Tags: , ,

So, I have this little problem…

  • For design reasons, I must use SQLObject. SQLAlchemy is cool but managing all my relations ‘by hand’ is a very time consuming task and TurboGears implementation of ActiveMapper is unstable, at best.
  • Turboentity was a good replacement using SQLA, but the project was dropped and merged with ActiveMapper, they’re all working on a new ORM layer for SQLA but right now, there’s not even an unstable one… ITOH, SO is the TG 1.0 official db layer, so it’s better supported.
  • I host my turbogears projects on rimuhosting, on a Virtual Machine. The thing is, memory is a little tight and running apache/php/mysql for wordpress consumes most of it. My Trac/SVN system use little resources.
  • I’ll finish in some weeks a TG app that, I hope, will attract a considerable ammount of users. I’m developing using a database in SQLite, but there’s no way to use that as a production db to something that can grow fast. And then my problems start…

MySQL/SQLObject UTF support seems to be erratic, I have run into problems before with this combination and on the TG group you can see any people complaining about a lot of problems with utf-8 and how mysql is erratic about it. My other choice is to use Postgres, but I don’t think that would fit on my brain-limited hosting machine, and removing MySQL is a problem because WordPress uses it (my blog…) and has no PGsql port avaiable.

So, anyone uses MySQL + SO or UTF and got some tips on the matter? How to make it work or at least do not be so buggy? I’ll be handling data from a lot of languages and I’ll just hate to spend time and time trying to debug some query that doesn’t work because of utf errors…

Technorati Tags: , , ,