<?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.muchinfo.mtp3interface.mapper.ITradefeedescriptionMapper">

    <!-- 通用查询映射结果 -->
    <resultMap id="BaseResultMap" type="com.muchinfo.mtp3pojos.entity.Tradefeedescription">
        <id column="TRADEFEEDESCRIPTIONID" property="tradefeedescriptionid" />
        <result column="TRADEFEEID" property="tradefeeid" />
        <result column="TRADEFEENAME" property="tradefeename" />
        <result column="REMARK" property="remark" />
    </resultMap>

    <!-- 通用查询结果列 -->
    <sql id="Base_Column_List">
        TRADEFEEDESCRIPTIONID, TRADEFEEID, TRADEFEENAME, REMARK
    </sql>

    <select id="query" resultMap="BaseResultMap">
        select o.* from TradeFeeDescription o, TradeFeeConfig c
        where
                o.tradefeedescriptionid = c.tradefeedescriptionid
                and c.tradepropertyid= #{tradeproperty}
                and o.tradefeeid in
        <foreach collection="idList" item="item" separator="," open="(" close=")" index="index">
            #{item}
        </foreach>
    </select>


</mapper>
