From 69684f689c0f4ab4ac97cdd7652e778d304ce9aa Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Thu, 1 Jun 2023 18:31:08 +0200 Subject: [PATCH] use correct collation_connection in --view mysqltest should use the same collation_connection in the service connection (that creates views) as in the main connection this makes weight_string("aaa") to return the expected value in --view and fixes main.func_str failure in --view --- client/mysqltest.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/client/mysqltest.cc b/client/mysqltest.cc index e745f8a3d2f..219b5532a70 100644 --- a/client/mysqltest.cc +++ b/client/mysqltest.cc @@ -8943,6 +8943,8 @@ int util_query(MYSQL* org_mysql, const char* query){ org_mysql->unix_socket); cur_con->util_mysql= mysql; + if (mysql->charset != org_mysql->charset) + mysql_set_character_set(mysql, org_mysql->charset->csname); } } else