向数据库添加值为null时 报错------- 
报错信息:org.apache.ibatis.type.TypeException: Error setting null for parameter #8 with JdbcType OTHER . Try setting a different JdbcType for this parameter or a different jdbcTypeForNull configuration property. Cause: java.sql.SQLException: 无效的列类型: 1111

 

我的解决方法:在mybatis-config.xml中插入  <setting name="jdbcTypeForNull" value="NULL"/>就解决了

如图:
org.apache.ibatis.type.TypeException: Error setting null for parameter #8 with JdbcType OTHER . Try

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-02-24
  • 2021-12-14
  • 2022-12-23
  • 2022-12-23
  • 2021-12-17
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2019-08-30
  • 2021-06-12
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案