ysql1,中文数据在插入时会出现乱码问题。为解决这个问题,需要进行以下步骤:
ysqlysql容器:
```ameysqlysqleral_ci
ysql容器内部,使用以下命令修改数据库的默认字符集:
```ysqlt = utf8;ysqlnection = utf8;ysql>SET character_set_database = utf8;ysql>SET character_set_results = utf8;ysql>SET character_set_server = utf8;
ysqlysqlysqlyfysqld]下添加以下两行:
```ysqld]
character-set-server=utf8
ysql服务:
```ysql restart
ysqlysqlysql:
```ysql -h127.0.0.1 -uroot -p123456 --default-character-set=utf8
ysql中文乱码问题。