Hi guys,
I noticed when installing Revo on our server, that despite selecting utf8 as the DB char set, when I view the tables ìn phpmyadmin, they show as collation: latin1_swedish_ci
Is this a default setting in MySQL I wonder that is causing tables to default to this collation?
Things are all working fine, just wondering if there are any negative repercussions to using this charset, or if changing the old DB’s to utf8 is going to cause issues (most likely I would imagine....)
Cheers,
J
-
MODX Staff
- 10,725 Posts
If you created the database yourself, it’s whatever collation you specified, or the default set for the server environment (which is typically latin1_swedish_ci). When MODx creates the database itself, it makes sure to specify the collation and charset, but if you have to pre-create the database in your environment, you need to make sure you create that database with the proper charset/collation. MODx uses whatever the database container specifies as it’s collation when creating the tables.
Ah yes this is what is happening.
I always create the DB, but am obviously not specifying the collation.
-
☆ A M B ☆
- 24,524 Posts
I find that when creating a new database in CPanel, it doesn’t give me a default collation option, and I have to go into phpMyAdmin right away to set the collation. I’ve often wondered why MySQL didn’t get its default settings changed to utf-8 years ago.
-
☆ A M B ☆
- 24,524 Posts
You’ll probably never have any issues with it.
Many web sites (maybe most) have that charset, but if you want to convert, some people have had luck with this:
http://bobsguides.com/convert-db-utf8.html. It’s not a trivial process.
I’m glad it worked for you.