Today I got the following error in an application which uses doctrine2
Message: SQLSTATE[HY000]: General error: 1267 Illegal mix of collations (latin1_swedish_ci,IMPLICIT) and (utf8_unicode_ci,COERCIBLE) for operation 'like'
I checked with phpmyadmin that the collation of the table is latin1_swedish_ci.
Within my application I configured doctrine to use utf8
$em->getEventManager()->addEventSubscriber(new \Doctrine\DBAL\Event\Listeners\MysqlSessionInit('utf8', 'utf8_unicode_ci'));
My database was generated via install script threw an equal configured entity manager.
How to set my table's collation to utf8_general_ci using doctrine2?