<!--?無意之中,再一次打開我的配置文件出現(xiàn)了一個(gè)錯(cuò)誤,標(biāo)注在mapper標(biāo)簽開始的位置:
????錯(cuò)誤的內(nèi)容為:The?content?of?element?type?"mapper"?must?match?"(cache-ref|cache|resultMap*|parameterMap*|sql*|insert*|update*|delete*|
?select*)+".
???在線急等求解答!
?-->
<?xml?version="1.0"?encoding="UTF-8"?>
<!DOCTYPE?mapper
??PUBLIC?"-//mybatis.org//DTD?Mapper?3.0//EN"
??"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper??namespace="dao.JaigeDao">
<!--?添加新數(shù)據(jù)?-->
<insert?id="SaveJiage"?parameterType="Jiage">
insert?into
xcphonefix.jiage(jgnum,pjid,xhid)
values
(#{jgnum},#{pjid},#{xhid})
</insert>
<!--?分頁查詢?start?-->
<!--?分頁查詢所有數(shù)據(jù)?-->
<select?id="indexSee"?resultType="Jiage"?parameterType="map">
select
?*?
from?jiage?
where?pjid?=?#{topPJid}?and?xhid?#{topXHid}
limit?#{0},#{0}
</select>
<!--?返回的價(jià)格數(shù)據(jù)集合?-->
<resuleMap?type="Jiage"?id="JiageMapper">
<id?column="jgid"?property="jgid"/>
<association?property="xinghao"?column="xhid"?javaType="Xinghao">
<id?column="xhid"?property="xhid"/>
<association?property="pinpai"?column="ppid"?javaType="Pinpai">
<id?column="ppid"?property="ppid"/>
</association>
</association>
<association?property="peijian"?column="pjid"?javaType="Peijian">
<id?column="pjid"?property="pjid"/>
</association>
</resuleMap>
<!--?更新數(shù)據(jù)?start?-->
<!--?拉取展示數(shù)據(jù),用以編輯?-->
<select?id="SeeAllJiage"?resultType="JiageMapper"?parameterType="map"?>
select?jgid,jgnum,pjname,xhname,ppname,jgShow
from?xcphonefix.jiage?j?
left?join?xcphonefix.peijian?pj?on?j.pjid=pj.pjid
left?join?xcphonefix.xinghao?xh?on?j.xhid=xh.xhid
order?by?pubdate?DESC?
limit?#{pagebegin},#{pagesize}
</select>
<!--?拉取要更新的數(shù)據(jù)?-->
<select?id="SeeOneJiage"?resultType="Jiage"?parameterType="int">
select
jgid,jgnum,pjid,xhid,jgShow
from?xcphonefix.jiage?where?jgid=#{jgid}
</select>
<!--?更新數(shù)據(jù)?-->
<update?id="updateJiage"?parameterType="map">
update??
set?jgnum=#{jgnum},pjid=#{pjid},xhid=#{xhid},jgShow=#{jgShow}
where?jgid=#{jgid}
</update>
<!--?更新數(shù)據(jù)?end?-->
<!--?刪除數(shù)據(jù)?start?-->
<delete?id="deleteJiage">
delete?from?xcphonefix.jiage?
where?jgid=#{jgid}
</delete>
<!--?刪除數(shù)據(jù)?end?-->
</mapper>
mybatis 配置文件錯(cuò)誤
XFE_星城前端_Peter
2016-02-12 22:59:09