springboot JPA报错No identifier specified for entity: XXXX 错误

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

是因为id注解引错的包

错误的包路径:

import org.springframework.data.annotation.Id;
正确的包路径:
import javax.persistence.Id;

猜你喜欢

转载自blog.csdn.net/Gr_lbxx/article/details/83181082
今日推荐