nextdreamblue opened a new issue, #9335: URL: https://github.com/apache/incubator-doris/issues/9335
### Search before asking - [X] I had searched in the [issues](https://github.com/apache/incubator-doris/issues?q=is%3Aissue) and found no similar issues. ### Description I need a mysql external table with utf8mb4 charset, but only support charset utf8 right now. If it can set charset when create mysql external table, it is better. for example: if there is a table with utf8mb4 charset on MySQL server. ```sql CREATE TABLE `abc_utf8mb4` ( `aaaa` char(100) NOT NULL DEFAULT '', `bbbb` varchar(16000) DEFAULT '', PRIMARY KEY (`aaaa`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; insert into abc_utf8mb4 values('111','😀 😃 😄 😁 😆 😅 😂 '); ``` on doirs, i create mysql external table for mysql table abc_utf8mb4, now like this: ```sql CREATE EXTERNAL TABLE `aaa` ( `aaaa` char(100) NULL COMMENT "", `bbbb` varchar(65533) NULL COMMENT "" ) ENGINE=MYSQL COMMENT "MYSQL" PROPERTIES ( "host" = "172.16.64.66", "port" = "3306", "user" = "root", "password" = "", "database" = "aaaa", "table" = "abc_utf8mb4" ); select * from aaa; ``` get result like this: +------+----------------+ | aaaa | bbbb | +------+----------------+ | 111 | ? ? ? ? ? ? ? | +------+----------------+ i expect result like this: +------+-------------------------------------+ | aaaa | bbbb | +------+-------------------------------------+ | 111 | 😀 😃 😄 😁 😆 😅 😂 +------+-------------------------------------+ ### Use case there is a table with utf8mb4 charset on MySQL server. ```sql CREATE TABLE `abc_utf8mb4` ( `aaaa` char(100) NOT NULL DEFAULT '', `bbbb` varchar(16000) DEFAULT '', PRIMARY KEY (`aaaa`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; insert into abc_utf8mb4 values('111','😀 😃 😄 😁 😆 😅 😂 '); ``` on doirs, i want create mysql external table for mysql table abc_utf8mb4, now like this: ```sql CREATE EXTERNAL TABLE `aaa` ( `aaaa` char(100) NULL COMMENT "", `bbbb` varchar(65533) NULL COMMENT "" ) ENGINE=MYSQL COMMENT "MYSQL" PROPERTIES ( "host" = "172.16.64.66", "port" = "3306", "user" = "root", "password" = "", "database" = "aaaa", "table" = "abc_utf8mb4" ); select * from aaa; ``` get result like this: +------+----------------+ | aaaa | bbbb | +------+----------------+ | 111 | ? ? ? ? ? ? ? | +------+----------------+ i expect result like this: +------+-------------------------------------+ | aaaa | bbbb | +------+-------------------------------------+ | 111 | 😀 😃 😄 😁 😆 😅 😂 +------+-------------------------------------+ ### Related issues https://github.com/apache/incubator-doris/issues/9137 ### Are you willing to submit PR? - [X] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org