首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 数据库 > 其他数据库 >

Mybatis3更新和剔除语句映射

2012-08-09 
Mybatis3更新和删除语句映射更新删除相对简单点,只要属性和类型对应即可。?模板?update idupdateAuthor

Mybatis3更新和删除语句映射

更新删除相对简单点,只要属性和类型对应即可。

?

模板

?

<update id="updateAuthor" parameterType="domain.blog.Author">update Author setusername = #{username},password = #{password},email = #{email},bio = #{bio}where id = #{id}     </update><delete id="deleteAuthor” parameterType=" int ">delete from Author where id = #{id}     </delete>

?

其属性值

?

?

<update  id="insertAuthor"  parameterType="domain.blog.Author"  flushCache="true"  statementType="PREPARED"  timeout="20000"> <delete  id="insertAuthor"  parameterType="domain.blog.Author"  flushCache="true"  statementType="PREPARED"  timeout="20000"> 

热点排行