<?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.njcn.gather.storage.mapper.DetectionDataDealMapper">


    <select id="listDisabledScriptDtlIndexs" resultType="java.lang.Integer">
        select distinct dtls.Script_Index
        from pq_script_dtls dtls
                 inner join ad_plan plan on dtls.Script_Id = plan.Script_Id
                 inner join pq_dev dev on dev.Plan_Id = plan.id
        where dev.id = #{devId}
          and dev.State = 1
          and dtls.Enable = 0
    </select>
</mapper>

