-
Notifications
You must be signed in to change notification settings - Fork 291
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MySQL database does not support 4-byte UTF-8 #2950
Comments
Older versions of MySQL only support UTF characters with 3 bytes. This excludes emoji - which require 4 bytes. Newer versions of MySQL support 4 byte UTF. Supporting 4-byte UTF is easy. Uprading existing sites is harder. |
Another problem is that most servers cannot create indexes on more than 767 bytes. For 3 byte (utf8), this is 255 characters. We currently have lots of columns with indexes and 255 characters. |
Is there an easy way to validate the input to warn or even disable the save button while 4byte uft is present in one field? |
I can't think of an easy solution or workaround. Using utf8mb4 on new installations is straightforward. We can create a test table that uses all the features that we need.
If this is sucessful, then we can use We then store the value in Updating existing databases has many difficulties. It may be impossible on some servers. |
Mysql <= 5.7.6 - does not support utf8mb4 MariaDB < 10.2.2- does not support utf8mb4 |
I can remember that the same problem was in Nextcloud 15. There the solution was: In the admin-backend there came up a message, that my database is not supporting utf8mb4 and I should update this. Doing But I don't know what |
This simply changes the default used for new tables. When we create tables/columns, we use an explicit collation - so this default value is never used. To "upgrade" the database from 3-byte UTF to 4-byte UTF we would need to modify every column. Also, modifying tables is slow. So an automatic upgrade is difficult, because each step may take longer than the webserver timeout limit. |
|
Hope to support utf8mb4_general_ci in version 2.1.0. |
Note: the surname/statistics code uses |
I got this error when adding a record with a note, my guess it's the UFT images, but if they are not supported they should be cleaned up
PS. name anonymised
The text was updated successfully, but these errors were encountered: