MktUnionCodeMapper.xml
968 Bytes
<?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.yoho.unions.dal.MktUnionCodeMapper" >
<resultMap id="BaseResultMap" type="com.yoho.unions.dal.model.MktUnionCode" >
<id column="id" property="id" jdbcType="INTEGER" />
<result column="union_type" property="unionType" jdbcType="BIGINT" />
<result column="code" property="code" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, union_type, code
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.Integer" >
select
<include refid="Base_Column_List" />
from mkt_union_code
where id = #{id,jdbcType=INTEGER}
</select>
<select id="selectByCode" resultMap="BaseResultMap">
select <include refid="Base_Column_List" />
from mkt_union_code
where code = #{code} limit 1;
</select>
</mapper>