35 lines
1.3 KiB
XML
35 lines
1.3 KiB
XML
<?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.example.demo.Dao.ZyUserDao">
|
|
<!-- <resultMap id="userMap" type="com.example.demo.Entity.ZyUser">-->
|
|
<!-- <id column="id" property="id"></id>-->
|
|
<!-- <result column="zname" property="zNAME"></result>-->
|
|
<!-- <result column="zpwd" property="zPwd"></result>-->
|
|
<!-- </resultMap>-->
|
|
|
|
|
|
<sql id="Base_Column_List">
|
|
zid, zname, zpwd
|
|
</sql>
|
|
|
|
|
|
<select id="selectByPrimaryKey" resultMap="com.example.demo.Entity.ZyUser" parameterType="java.lang.String">
|
|
select
|
|
<include refid="Base_Column_List"/>
|
|
from public.zy_user where zid = #{id}
|
|
</select>
|
|
|
|
<!-- <select id="getAllUsers" resultType="com.example.demo.Entity.ZyUser">-->
|
|
<!-- select zname as zName,zpwd as zPwd from public.zy_user where 1=1-->
|
|
<!--<!– <if test="id!=null">–>-->
|
|
<!--<!– AND id like concat ('%',#{id},'%')–>-->
|
|
<!--<!– </if>–>-->
|
|
<!-- <!– <if test="energy!=null and energy !='' ">–>-->
|
|
<!-- <!– AND energy like concat ('%',#{energy},'%')–>-->
|
|
<!-- <!– </if>–>-->
|
|
<!-- </select>-->
|
|
</mapper>
|