Mysql问题 问题描述 当后端使用的是SpringJPA作为持久层的结局方案时,前端做新增请求时报错could not execute statement; nested exception is org.hibernate.exception.GenericJDBCException: could not execute statement 问题解决 解决方式 到mysql给相应的表的 主键 字段设置 “自增” 问题原因 是对应的pojo的设置了id自增的注解,但是mysql本身并没有给id设置自增,所以当新增时就出现了冲突