Closed xhy1999 closed 11 months ago
和mp无关
目前我这边debug下来,发现在org.apache.ibatis.executor.resultset.DefaultResultSetHandler
的applyAutomaticMappings
方法中final Object value = mapping.typeHandler.getResult(rsw.getResultSet(), mapping.column);
这一行获取的结果出现了\
而非\
看类名,那是mybatis的
是的是的,我发现了,不好意思额
最终发现是数据库表的字符集设置成了ujis
,将其改为utf8
就正常了,实在不好意思
当前使用版本(必填,否则不予处理)
操作系统: Win10 22H2 Java: JDK_1.8.0_291 数据库: MySQL 5.7.34 (字符集utf8mb4) 依赖:
该问题是如何引起的?(确定最新版也有问题再提!!!)
数据库连接地址:
jdbc:mysql://127.0.0.1:3306/db_test?useSSL=false&useUnicode=true&characterEncoding=utf-8&serverTimezone=Asia/Shanghai
实体类:Mapper:
Service:
ServiceImpl:
重现步骤(如果有就写完整)
执行test()后日志输出:
下面一行的字符 U+ff3c"\"不是基本ASCII字符
,导致后续通过路径读取文件时出现异常。\
报错信息
无