Sample Header Ad - 728x90

Can I change the collation of a table and its columns without using convert to?

2 votes
2 answers
107 views
All of the tables and columns in my database are using the utf8mb4 character set and utf8mb4_unicode_ci collation. I'd like to migrate to utf8mb4_0900_ai_ci collation but using convert to is prohibitive on my large tables unless I use gh-ost or pt-osc. It seems to me that convert to should not be necessary since the character set is not changing, but I cannot find any documentation which confirms or denies this. Do I need to use convert to in this case, or is alter table ... modify col ... collate ... sufficient? I've looked https://dba.stackexchange.com/questions/229954/using-convert-to-character-set-for-changing-only-collation which asks a very similar question, but the age of that question renders the answers somewhat obsolete. Even so, one answer seems to imply that convert to is unnecessary. The other answer delves into character set conversion and using pt-osc which I'd hoping to avoid.
Asked by Joel (133 rep)
Apr 4, 2025, 09:01 PM
Last activity: Apr 8, 2025, 05:39 PM