Mybatis连接mysql数据库的时候,设置字符集编码!!!
可以如下配置,Mybatis的配置文件中要这样写:
db.propertise
jdbc.driver=com.mysql.jdbc.Driver
jdbc.url=jdbc:mysql://localhost:3306/mybatis?characterEncoding=utf-8
jdbc.username=root
jdbc.password=123
Mybatis连接mysql数据库的时候,设置字符集编码!!!
可以如下配置,Mybatis的配置文件中要这样写: