Does anybody know if ProxySQL supports utf8mb4_0900_as_ci collation?
It supports utf8mb4_0900_ai_ci, but I specifically need utf8mb4_0900_as_ci.
It is not in the mysql_collations table.
I inserted it in that table with the proper Id and charset but it didn’t work.
I’d like to know if it’s possible to add support in ProxySQL for a missing collation.
Thanks!
You might want to open a github issue with ProxySQL for this. What error are you seeing when you manually add this collation to proxsql?
Before manually adding the collation I get this error: Syntax error or access violation: 1115 Unknown character set ‘utf8mb4’ or collation ‘utf8mb4_0900_as_ci’
After adding it to the mysql_collation table, I still get the same error.
Unfortunately, there’s no “load MySQL collations to runtime” command
When I restarted ProxySQL service, the collation I added was gone.
So, I guess the mysql_collation table is not prepared to accept new elements.
I’ll try opening a GitHub issue for this. Thanks!
What happens if you connect first, then switch the collation?
SET NAMES 'utf8mb4' COLLATE 'utf8mb4_0900_as_ci';
Or set the default in proxysql, mysql-default_collation_connection
I tried both. When I use the SET NAMES command I get the error Unknown character set ‘utf8mb4’ or collation ‘utf8mb4_0900_as_ci’
Then I looked in the global_variables table, but there’s no row for mysql-default_collation_connection.
I tried adding a row with that variable_name, but it goes away when I execute load MySQL variables to runtime.
I guess I have a problem with the ProxySQL Admin, because I first installed ProxySQL 1.x, then installed ProxySQL 2.4 but the admin module is the same as before, and I don’t know how to erase all of the ProxySQL configuration in order to start fresh with version 2.4.
Stop proxysql. rm -f /var/lib/proxysql/* Start proxysql 2.4. This will re-init everything.
Thank you!! It worked like magic
Just to clarify, all you did was upgrade to ProxySQL 2.4 and your collation now works? Did you have to add it to ProxySQL or did SET NAMES work just fine?
I also had to do this
after restarting everything, this setting: mysql-default_collation_connection
began to show up in the global_variables table.