> Do the difficulties occur only with the old data or do you see the
> same behaviour if you bootstrap a clean database and run from that?
>
> Your UnicodeDecodeError looks hauntingly familiar and it was caused by
> corrupted data in the database. I suspect that by changing the
> encoding with existing data will have caused problems. I assume that
> you have a backup of your database from before you made these changes?
>
> I have a script that uses SA to go through every row of every table
> and fixes encoding issues, but it's fairly dangerous in that it hasn't
> been widely tested and could break your data further. I will send it
> along privately as it really isn't fit for public consumption and you
> can test it on a backup of your database to see if it solves your
> issues.
First, thanks to everyone who pitched in for me!
Here's where I'm at now:
- updated mysqldb to 1.2.2, and added ?charset=utf8 to the dburi line
- dropped database, made fresh one with charset=utf8
- unicode going in ok!
Question:
What is the smart thing to do about the existing live site? MySQLdump
dumps with utf8, so could I safely do the following:
- do a data only dump, ( mysqldump -ct etc )
- drop the db
- make a new one with charset utf-8
- stick the data back in
Also, I did not need to do the
sys.setdefaultencoding('utf8')
tip, is that something I should do as well? I'm a bit more afraid of
that one.
Thanks everyone
Iain
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---