Default database collation should be utf8_unicode_ci

Which features are you missing? Tell us about it.
Post Reply
shoulders
Posts: 70
Joined: Wed 25. Oct 2023, 21:05

Default database collation should be utf8_unicode_ci

Post by shoulders »

The default collation for tables in phpMyAdmin is utf8mb4_general_ci but should be utf8mb4_unicode_ci. This setting might be server thing or a phpMyAdmin setting. I cannot remember it has been a while.
db collation.png
db collation.png (9.86 KiB) Viewed 1030 times
The 'Server connection collation' is already utf8mb4_unicode_ci
server connection.png
server connection.png (15.95 KiB) Viewed 1030 times
utf8mb4_unicode_ci is a much more efficient search algorithm and the extra overheads are minimal. This is also the standard collation that WordPress now uses for its tables where it can.

I can probably figure out how to change this myself, but for new installs this should be set tot he new collation of utf8mb4_unicode_ci

shoulders
User avatar
Florian
Keyweb AG
Posts: 1261
Joined: Wed 20. Jan 2016, 02:28

Re: Default database collation should be utf8_unicode_ci

Post by Florian »

Hello,

it is the default setting of MariaDB. Keyhelp does not change anything here.
Mit freundlichen Grüßen / Best regards
Florian Cheno

**************************************************************
Keyweb AG - Die Hosting Marke
Neuwerkstr. 45/46, 99084 Erfurt / Germany
http://www.keyweb.de - http://www.keyhelp.de
**************************************************************
shoulders
Posts: 70
Joined: Wed 25. Oct 2023, 21:05

Re: Default database collation should be utf8_unicode_ci

Post by shoulders »

Then maybe KeyHelp could change this setting with a modification to a script. This is a really poor collation to be using.

For reference:
Last edited by shoulders on Thu 26. Oct 2023, 12:11, edited 1 time in total.
User avatar
24unix
Posts: 1643
Joined: Sun 21. Jun 2020, 17:16
Location: Kollmar
Contact:

Re: Default database collation should be utf8_unicode_ci

Post by 24unix »

shoulders wrote: Thu 26. Oct 2023, 11:59 Then maybe KeyHelp could change this setting with a modification to a script. This is a really poor collation to be using.
Then the DBA should use what he likes better, you can change it anytime. The defaults are not really important.
mfg Micha
--
If Bill Gates had a nickel for every time Windows crashed …
… oh wait, he does.
User avatar
Alexander
Keyweb AG
Posts: 3842
Joined: Wed 20. Jan 2016, 02:23

Re: Default database collation should be utf8_unicode_ci

Post by Alexander »

shoulders wrote: Thu 26. Oct 2023, 11:59 Then maybe KeyHelp could change this setting with a modification to a script. This is a really poor collation to be using.
You may want to ask the operating system vendors, why they set the default to utf8mb4_general_ci instead of utf8mb4_unicode_ci.

I had a look:
- Ubuntu 22 uses utf8mb4_general_ci
- Debian 12 uses utf8mb4_general_ci
Mit freundlichen Grüßen / Best regards
Alexander Mahr

**************************************************************
Keyweb AG - Die Hosting Marke
Neuwerkstr. 45/46, 99084 Erfurt / Germany
http://www.keyweb.de - http://www.keyhelp.de
**************************************************************
Post Reply