Dear Glorp experts,
I'll try o make a long story short:I am chewing on this crazy idea to switch from one database (db2) to another one (postgresql), going from VA Smalltalk 32 bits to 64. Let's say this is more a business decision than a technical one.
Once I do the switch, I might as well go and transform all my Strings in the database from ISO-8859-1(5) to UTF-8. The complicated thing here is that, in its current version, VA Smalltalk is not (yet) using utf-8 internally. So what would be needed (at least temoorarily until VAST supports UTF-8 natively) is some form of encoding/decoding whenever data travels between the databse and Glorp, resp, the image. My naive idea here would be that whenever we send out an SQL statement to the DB and whenever something comes back from the DB, we just convert the Strings from/to utf-8.
I wonder about a few things here:
- is this a job that Glorp would provide a hook or even some functionality for? Or should I be lloking at the underlying Database Interface classes?
- How do people calculate their CHAR and VARCHAR sizes for utf-8? A straight "number of characters times 4" sounds a bit much, at least for German, because we only have a hand full of special characters and our words contain quite a few ascii letters...
- Has anybody done a database migration using Glorp? Any tips for ready for sharing? Recommendations for tools to do the migration? I need Sequences to be consecutive on the new database and need to port triggers and stored procs along with the data...
So if any of you happen to have ideas on one or more of these topics and has a few ideas, caveats, heads up to share, I'd be grateful. And I am sure there are more people on this planet who'd like to learn about them...
Joachim