If you see an "Incorrect string value" error in Django and you're using MySQL, run
SELECT * FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME = 'your-table-name'
and check the CHARACTER_SET_NAME for the column in question.
If it's not set correctly (e.g., it's latin1 and you're trying to insert utf8), change it with
alter table table modify column type character set utf8;
Core dumped.
Subscribe to:
Post Comments (Atom)
0 comments:
Post a Comment