<?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.StandardDao">
<select id="findAll" resultType="entity.Standard">
SELECT * FROM `standard` WHERE (std_num LIKE CONCAT('%',#{name},'%')
or zhname like CONCAT('%',#{name},'%') )
and bdelete='0'
GROUP BY std_num ASC LIMIT #{pageno},3
</select>
<select id="getCount" resultType="int">
SELECT count(*) FROM `standard` WHERE std_num LIKE CONCAT('%',#{name},'%')
or zhname like CONCAT('%',#{name},'%')
</select>
<update id="bdelete" >
update `standard` set bdelete=1 where id in
<foreach collection="array" open="(" close=")" item="id" separator=",">
#{id}
</foreach>
</update>
</mapper>