Mapper的.xml文件的delete的参数问题

<?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="com.how2java.mapper.CategoryMapper">
<select id="list" resultType="Category">
select * from category_
</select>

<delete id="delete" parameterType="int">
delete * from category_ where id = #{id}                  //问题!!!!!!!使用#{}传参
</delete>
</mapper>

Mapper的.xml文件的delete的参数问题

上一篇:Mybatis:通过MapperScannerConfigurer进行mapper扫描


下一篇:寒冬之下,移动开发没人要了? 浅谈 iOS 开发者该 何去何从?