Cannot obtain primary key information from the database, generated objects may be incomplete

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/babybabyup/article/details/84099469

前言

最近在做springboot 一直踩坑

问题描述

在整合mybatis时只是生成了两个insert()函数,并且提示
[WARNING] Cannot obtain primary key information from the database, generated objects may be incomplete

问题展示

解决方法

在jdbc连接url上加nullCatalogMeansCurrent=true

url=jdbc:mysql://localhost:3306/helloword?useUnicode=true&characterEncoding=utf-8&nullCatalogMeansCurrent=true

亲测已经解决
解决图片

解决之后

猜你喜欢

转载自blog.csdn.net/babybabyup/article/details/84099469