I tried to migrate my AWS RDS instance from Aurora to MySQL. I created a dump file from the Aurora and imported it into the MySQL instance.
Both instances have the same characters set.
mysql> show variables like '%char%';
+--------------------------+-------------------------------------------+
| Variable_name | Value |
+--------------------------+-------------------------------------------+
| character_set_client | utf8mb4 |
| character_set_connection | utf8mb4 |
| character_set_database | latin1 |
| character_set_filesystem | binary |
| character_set_results | utf8mb4 |
| character_set_server | latin1 |
| character_set_system | utf8 |
| character_sets_dir | /rdsdbbin/mysql-5.7.26.R1/share/charsets/ |
+--------------------------+-------------------------------------------+
In the original DB the Hebrew letters appears as black diamonds (Converted to Hebrew in app side). After the migration to the new MySQL instance, instead of black diamonds i see questions marks.
What could be the issue?
Best Answer
I think your problem is that you have exported your dump file with ANSI character set, to take a dump file using UTF8, issue your
mysqldump
command with option--default-character-set=utf8
and check the results. (AFAIK the same options for mysqldump work for Aurora as well)PS : After your comments, I dug the problem a bit more. The problem comes from different configurations for
character-set-system
(which isutf8
),character_set_server
(which islatin1
) withcharacter-set-client
(which isutf8mb4
). Based on this link to documentation, this difference might cause issues in data input and may result in bad format in output. You can check the validity of this root cause by changing your character sets for different components.