I am using Django 1.5.4 with Django-Regsitration module. whenever I try to register a user with Persian fonts I get this error:
DatabaseError at /accounts/register/
(1267, "Illegal mix of collations (latin1_swedish_ci,IMPLICIT) and (utf8_general_ci,COERCIBLE) for operation 'like'")
Request Method: POST
Request URL: http://127.0.0.1:8000/accounts/register/
Django Version: 1.5.4
Exception Type: DatabaseError
I have the similar problem with other forms that I've created: Whenver I fill a field with Persian font, I get error like:
Warning at /accounts/profile/
Incorrect string value: '\xDA\xA9\xD8\xA7\xD8\xB1...' for column 'occupation' at row 1
To resolve it I did:
Using PhpMyAdmin I've changed collation of the database to 'utf8_general_ci
Had no effect.
I have also enforce the utf8 on the DB:
mysql> ALTER DATABASE djangodb charset=utf8;
Still no effect.
So appreciate your hints.