<?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="io.dataease.base.mapper.ext.ExtDataSetTaskMapper">

    <resultMap id="BaseResult" type="io.dataease.dto.dataset.DataSetTaskLogDTO"
               extends="io.dataease.base.mapper.DatasetTableTaskLogMapper.BaseResultMap">
        <result column="name" jdbcType="VARCHAR" property="name"/>
    </resultMap>

    <select id="list" resultMap="BaseResult" parameterType="io.dataease.base.domain.DatasetTableTaskLog">
        SELECT dataset_table_task_log.*,
        dataset_table_task.name
        FROM dataset_table_task_log
        LEFT JOIN dataset_table_task ON dataset_table_task_log.task_id = dataset_table_task.id
        WHERE dataset_table_task_log.table_id = #{tableId,jdbcType=VARCHAR}
        ORDER BY dataset_table_task_log.create_time desc
    </select>

</mapper>
