MySQL Unknown collation: utf8mb4_unicode_520_ci

When i restore a MySQL database backup taken on MairaDB 10 on MySQL 5.5, i get error

root@48b55e4d9b35:/home/boby# mysql -u root -pflashwebhost wp < wp.sql
ERROR 1273 (HY000) at line 356: Unknown collation: 'utf8mb4_unicode_520_ci'
root@48b55e4d9b35:/home/boby#

To fix this, i changed all instance of utf8mb4_unicode_520_ci in the SQL backup file with utf8mb4_unicode_ci with sed.

sed -i 's/utf8mb4_unicode_520_ci/utf8mb4_unicode_ci/g'  wp.sql
Advertisement
Add a comment

Leave a Reply

Your email address will not be published. Required fields are marked *

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Advertisement