解决数据库插入报错问题:auto_increment字段未赋值

内容概览
在使用代码生成报服务器错误时,后台报错显示 'Field 'auto_increment' doesn't have a default value'。经过排查,发现 infra_codegen_column 表的 auto_increment 字段未赋值。insert 语句中确实没有为该字段赋值,导致了报错。本文将详细介绍问题的解决方法。
limz
2024-08-07 17:37
赞1评论7
使用代码生成报服务器错误。 后台报错 “### Error flushing statements. Cause: org.apache.ibatis.executor.BatchExecutorException: cn.iocoder.yudao.module.infra.dal.mysql.codegen.CodegenColumnMapper.insert (batch index #1) failed. Cause: java.sql.BatchUpdateExc...

芋道快速开发平台 Boot + Cloud

星球已运营 4 年零 211 天

累计超过  34000+  位成员加入

6小时前

最近更新

40000+

内容数

进入星球主页