6

Recently I've installed PHP7 on my MAMP and updated to newest version of WordPress. Every time I do a new site all my tables are using collation utf8mb4_unicode_520_ci

I have tried setting define('DB_COLLATE', 'utf8_general_ci'); in my wp-config.php which worked fine until Gravity Forms ignored it and created all it's tables in utf8mb4_unicode_520_ci

I've seen that if utf8mb4_unicode_520_ci is available it will use that so is there a surefire way to stop WP using that collation? Can I just remove that collation as I am having to run 10 ALTER TABLE queries before I can port the database over to staging/live server?

  • Should there be a good reason for this? Why do you have to convert? – Nathan Powell Sep 28 '16 at 5:58
  • Gravity forms is powerful, but do you need it? If you do, maybe your system should support it. – Nathan Powell Sep 28 '16 at 6:01
  • bumping this. I have the same problem. My local machine has a higher version of MySQL. I used to be able to do a sync of DB to deploy my sites. Now because of the different collation, I can't sync anymore. This is a huuuugge problem. – resting Oct 5 '16 at 2:51
  • I have the same issue while developing locally. Pushing up to my live database is always a pain because it never likes that collation. – Steve North Nov 1 '16 at 10:41
  • If this is an issue specific to the plugin, then you should open up a ticket on the WordPress.Org page for the plugin. – Cedon Mar 19 '17 at 19:21
0

I ran into a similar issue while deploying sites using BackupBuddy. Ninja Forms was constantly creating tables in unicode_520_ci, no matter what settings I used in Sequel Pro.

Not sure if this helps or not, but all I had to do was change the collation within Sequel Pro for the specific Ninja Forms tables, and then the deployment would work as normal.

0

Not using utf8mb4_unicode.... collation and using a utf8 one instead is a security problem. The right answer is to upgrade your sites and DBs so they all use utf8mb4

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.