修改/etc/my.cnf character-set-server=utf8
[client] default-character-set=utf8
注释掉 sql_mode
重新新建mysql表
在hive的元数据库中执行以下SQL语句,然后重新创建刚才的表即可 。
alter table COLUMNS_V2 modify column COMMENT varchar(256) character set utf8; alter table TABLE_PARAMS modify column PARAM_VALUE varchar(4000) character set utf8; alter table PARTITION_PARAMS modify column PARAM_VALUE varchar(4000) character set utf8; alter table PARTITION_KEYS modify column PKEY_COMMENT varchar(4000) character set utf8; alter table INDEX_PARAMS modify column PARAM_VALUE varchar(4000) character set utf8;
不行的话在hive-site.xml的jdbc连接中加入?useSSL=false&characterEncoding=UTF-8
|