使用springboot讲中文字符传输到数据库后乱码

在url路径后加上

?useUnicode=true&characterEncoding=utf-8参数

例子:

  

url: jdbc:mysql://localhost:3306/jpa_demo?serverTimezone=GMT%2B8&useUnicode=true&characterEncoding=utf-8

猜你喜欢

转载自blog.csdn.net/qq_36957587/article/details/84304168