You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
821 B
26 lines
821 B
<?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="mapperDAO.yhMapperDao">
|
|
<resultMap id="yhMap" type="domain.yhPO">
|
|
<id column="s_id" jdbcType="int" property="s_id" />
|
|
<result column="s_password" jdbcType="VARCHAR" property="s_password" />
|
|
<result column="s_name" jdbcType="VARCHAR" property="s_name" />
|
|
</resultMap>
|
|
<select id="search" resultMap="yhMap" parameterType="String">
|
|
SELECT
|
|
student.s_id,
|
|
student.s_name,
|
|
student.s_password,
|
|
FROM
|
|
student
|
|
WHERE
|
|
student.s_id=#{s_id}
|
|
</select>
|
|
|
|
<select id="update" parameterType="domain.yhPO">
|
|
UPDATE yh.student
|
|
SET s_id=#{s_id},s_password=#{s_password},s_name=#{s_name}
|
|
WHERE student.s_id=#{s_id};
|
|
|
|
</select>
|
|
</mapper> |