![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
java框架
Pengzi@USC
闲时与你立黄昏,灶前笑问粥可温
展开
-
解决mybatis问题:The content of element type "mapper" must match "(cache-ref|cache|resultMap*|parameterMa
今天在练习mybatis 的时候发现标题上面的错误:The content of element type "mapper" must match "(cache-ref|cache|resultMap*|parameterMap*|sql*|insert*|update*|delete*|select*)+"主要原因是:1、标签不完整,没有成对的出现<inser...原创 2019-08-29 17:07:38 · 4536 阅读 · 0 评论 -
Mapped Statements collection does not contain value for的解决方法
错误原因有几种:1、mapper.xml中没有加入namespace2、mapper.xml中的方法和接口mapper的方法不对应3、mapper.xml没有加入到mybatis-config.xml中(即总的配置文件),例外:配置了mapper文件的包路径的除外4、mapper.xml文件名和所写的mapper名称不相同。...转载 2019-08-29 17:19:16 · 2103 阅读 · 1 评论 -
MyBatis学习(二)
一、获取插入的sql数据的自增编号er二、非自增主键的返回使用mysql的uuid()函数生成主键,需要修改表中的id字段类型为string,长度设置成35位,执行思路: 先通过uuid()查询到主键,再将逐渐输入到sql语句中 执行uuid语句相对于insert语句之前执行二、更新操作...原创 2019-08-29 20:20:18 · 86 阅读 · 0 评论