0

I am having trouble creating a new View. I am just testing out the module, but when I click "Save" after setting everything up, I receive the following error:

PDOException: SQLSTATE[HY000]: General error: 1267 Illegal mix of collations (utf8_general_ci,IMPLICIT) and (utf8_unicode_ci,IMPLICIT) for operation '=': SELECT s.uid, c.updated FROM {ctools_object_cache} c INNER JOIN {sessions} s ON c.sid = s.sid WHERE s.sid <> :session_id AND c.obj = :obj AND c.name = :name ORDER BY c.updated ASC; Array ( [:session_id] => 3nTvCCvx2_Zopg07JqIBReKxL3TzvilIkwmHjFKZ93o [:obj] => view [:name] => recently_posted_jobs ) in ctools_object_cache_test() (line 145 of /home1/mt/public_html/mtnet/sites/all/modules/ctools/includes/object-cache.inc). The website encountered an unexpected error. Please try again later.

Any ideas why this is happening?

0

Clear all your caches and try again.

You db seems to become corrupted or misconfigured. Your ctools module is using a different collation to store values in the db. So most of your site is utf8_general_ci and the ctools is using utf8_unicode_ci.

I gathered all of that from this line:

(utf8_general_ci,IMPLICIT) and (utf8_unicode_ci,IMPLICIT) for operation '=': SELECT s.uid, c.updated FROM {ctools_object_cache}


If the clearing of caches fails then...

If you have phpmyadmin installed, go to the site's db and check what the Collate value is. Try changing it to utf_8 or something.


NOTE: I would create a backup of the db before you play with any collate value stuff.

  • I followed your advice, and it worked! For posterity, I changed the "Collation" field for the ctools_css_cache, ctools_custom_content, and ctools_object_cache tables in my database to utf8_unicode_ci. Make sure the Collation value is the same for all tables in your database, otherwise you'll experience the same issues I did. So it doesn't have to be "utf8_unicode_ci", that's just what the Collation value was for all of the other tables in my DB, so it's what I settled on. As long as there's consistency, you'll be good! – Lukas Pleva Feb 13 '14 at 19:21

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.