目前总结了六点


  • mybatis绑定错误
    mybatis绑定错误
    看上面两处方法名是否一样

  • mybatis绑定错误
    mybatis绑定错误
    看@param里面的参数名字与#{}里面的参数名字是否一样

  • mybatis绑定错误
    返回自定义映射用resultMap=“***”,返回实体用resultType=“***”

  • 返回的resultType与实际返回的类型是否相对应

  • 项目打包成war需要指定静态资源的打包
    mybatis绑定错误

  • springboot需要在.property或者.yml指定xml路径
    mybatis绑定错误
    写成com.forest.zhongruanspringboot.dao/*.xml也是可以的
    如果写成了com.forest.zhongruanspringboot.dao.*.xml会报绑定错误

相关文章: