<?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.ruoyi.ibs.grid.mapper.GridShapeCountMapper">

    <resultMap type="GridShapeCountGongsi" id="GridShapeCountGongsiResult">
        <result property="dt"    column="dt"    />
        <result property="shapeType"    column="shape_type"    />
        <result property="shapeId"    column="shape_id"    />
        <result property="shapeName"    column="shape_name"    />
        <result property="gridId"    column="grid_id"    />
        <result property="gridName"    column="grid_name"    />
        <result property="deptId"    column="dept_id"    />
        <result property="deptName"    column="dept_name"    />
        <result property="outletsId"    column="outlets_id"    />
        <result property="outletsName"    column="outlets_name"    />
        <result property="userName"    column="user_name"    />
        <result property="custNum"    column="cust_num"    />
        <result property="hqCurBalance"    column="hq_cur_balance"    />
        <result property="bzCurBalance"    column="bz_cur_balance"    />
        <result property="loanBalanceCny"    column="loan_balance_cny"    />
        <result property="financeProd711Balance"    column="finance_prod_711_balance"    />
        <result property="financeProd716Balance"    column="finance_prod_716_balance"    />
        <result property="loanYearDailyaverage"    column="loan_year_dailyaverage"    />
        <result property="htqyRat"    column="htqy_rat"    />
        <result property="qfcdRat"    column="qfcd_rat"    />
        <result property="txRat"    column="tx_rat"    />
        <result property="bhRat"    column="bh_rat"    />
        <result property="yxdfgzRat"    column="yxdfgz_rat"    />
        <result property="dkdfRat"    column="dkdf_rat"    />
        <result property="dksfRat"    column="dksf_rat"    />
        <result property="dkshfRat"    column="dkshf_rat"    />
        <result property="pjbRat"    column="pjb_rat"    />
        <result property="czbRat"    column="czb_rat"    />
        <result property="sfbRat"    column="sfb_rat"    />
        <result property="mrbRat"    column="mrb_rat"    />
        <result property="szstRat"    column="szst_rat"    />
        <result property="khRat"    column="kh_rat"    />
        <result property="gjjsywRat"    column="gjjsyw_rat"    />
        <result property="yqjshRat"    column="yqjsh_rat"    />
        <result property="htqyNum"    column="htqy_num"    />
        <result property="qfcdNum"    column="qfcd_num"    />
        <result property="txNum"    column="tx_num"    />
        <result property="bhNum"    column="bh_num"    />
        <result property="yxdfgzNum"    column="yxdfgz_num"    />
        <result property="ustrCountPerM"    column="ustr_count_per_m"    />
        <result property="ustrBalM"    column="ustr_bal_m"    />
        <result property="dkdfNum"    column="dkdf_num"    />
        <result property="dksfNum"    column="dksf_num"    />
        <result property="dkshfNum"    column="dkshf_num"    />
        <result property="pjbNum"    column="pjb_num"    />
        <result property="czbNum"    column="czb_num"    />
        <result property="sfbNum"    column="sfb_num"    />
        <result property="mrbNum"    column="mrb_num"    />
        <result property="szstNum"    column="szst_num"    />
        <result property="khNum"    column="kh_num"    />
        <result property="gjjsywNum"    column="gjjsyw_num"    />
        <result property="yqjshNum"    column="yqjsh_num"    />
        <result property="opsDept"    column="ops_dept"    />
    </resultMap>


    <resultMap type="GridShapeCountLingshou" id="GridShapeCountLingshouResult">
        <result property="dt"    column="dt"    />
        <result property="shapeType"    column="shape_type"    />
        <result property="shapeId"    column="shape_id"    />
        <result property="shapeName"    column="shape_name"    />
        <result property="gridId"    column="grid_id"    />
        <result property="gridName"    column="grid_name"    />
        <result property="deptId"    column="dept_id"    />
        <result property="deptName"    column="dept_name"    />
        <result property="outletsId"    column="outlets_id"    />
        <result property="outletsName"    column="outlets_name"    />
        <result property="userName"    column="user_name"    />
        <result property="custNum"    column="cust_num"    />
        <result property="curBalD"    column="cur_bal_d"    />
        <result property="curBalT"    column="cur_bal_t"    />
        <result property="balLoan"    column="bal_loan"    />
        <result property="curBal5Bad"    column="cur_bal_5_bad"    />
        <result property="curDAve"    column="cur_d_ave"    />
        <result property="curTAve"    column="cur_t_ave"    />
        <result property="loanAve"    column="loan_ave"    />
        <result property="phRat"    column="ph_rat"    />
        <result property="sxRat"    column="sx_rat"    />
        <result property="yxhtRat"    column="yxht_rat"    />
        <result property="xykRat"    column="xyk_rat"    />
        <result property="fshlRat"    column="fshl_rat"    />
        <result property="sdRat"    column="sd_rat"    />
        <result property="etcRat"    column="etc_rat"    />
        <result property="dianRat"    column="dian_rat"    />
        <result property="blackRat"    column="black_rat"    />
        <result property="badRat"    column="bad_rat"    />
        <result property="badBalRat"    column="bad_bal_rat"    />
        <result property="phNum"    column="ph_num"    />
        <result property="sxNum"    column="sx_num"    />
        <result property="yxhtNum"    column="yxht_num"    />
        <result property="xykNum"    column="xyk_num"    />
        <result property="fshlNum"    column="fshl_num"    />
        <result property="sdNum"    column="sd_num"    />
        <result property="etcNum"    column="etc_num"    />
        <result property="dianNum"    column="dian_num"    />
        <result property="blackNum"    column="black_num"    />
        <result property="badNum"    column="bad_num"    />
        <result property="opsDept"    column="ops_dept"    />
    </resultMap>


    <resultMap type="GridShapeCustGongsi" id="GridShapeCustGongsiResult">
        <result property="custName"    column="cust_name"    />
        <result property="socialCreditCode"    column="social_credit_code"    />
        <result property="custIsn"    column="cust_isn"    />
        <result property="hqCurBalance"    column="hq_cur_balance"    />
        <result property="bzCurBalance"    column="bz_cur_balance"    />
        <result property="isCredit"    column="is_credit"    />
        <result property="loanBalanceCny"    column="loan_balance_cny"    />
        <result property="loanYearDailyaverage"    column="loan_year_dailyaverage"    />
        <result property="isHtqy"    column="is_htqy"    />
        <result property="financeProd716OpenFlag"    column="finance_prod_716_open_flag"    />
        <result property="financeProd716Balance"    column="finance_prod_716_balance"    />
        <result property="financeProd711OpenFlag"    column="finance_prod_711_open_flag"    />
        <result property="financeProd711Balance"    column="finance_prod_711_balance"    />
        <result property="intlBussinessJcbhOpenFlag"    column="intl_bussiness_jcbh_open_flag"    />
        <result property="isUstr"    column="is_ustr"    />
        <result property="ustrCountPerM"    column="ustr_count_per_m"    />
        <result property="ustrBalM"    column="ustr_bal_m"    />
        <result property="elecchargeSignFlag"    column="eleccharge_sign_flag"    />
        <result property="waterchargeSignFlag"    column="watercharge_sign_flag"    />
        <result property="taxdeductionSignFlag"    column="taxdeduction_sign_flag"    />
        <result property="pjb"    column="pjb"    />
        <result property="czb"    column="czb"    />
        <result property="sfb"    column="sfb"    />
        <result property="mrb"    column="mrb"    />
        <result property="szst"    column="szst"    />
        <result property="isOpenSts"    column="is_open_sts"    />
        <result property="intlBussinessOpenFlag"    column="intl_bussiness_open_flag"    />
        <result property="intlBussiness325OpenFlag"    column="intl_bussiness_325_open_flag"    />
        <result property="shapeId"    column="shape_id"    />
        <result property="opsDept"    column="ops_dept"    />
        <result property="custType"    column="cust_type"    />
    </resultMap>


    <resultMap type="GridShapeCustLingshou" id="GridShapeCustLingshouResult">
        <result property="custName"    column="cust_name"    />
        <result property="custIdc"    column="cust_idc"    />
        <result property="custIsn"    column="cust_isn"    />
        <result property="curBalD"    column="cur_bal_d"    />
        <result property="curBalT"    column="cur_bal_t"    />
        <result property="balLoan"    column="bal_loan"    />
        <result property="curBal5Bad"    column="cur_bal_5_bad"    />
        <result property="curDAve"    column="cur_d_ave"    />
        <result property="curTAve"    column="cur_t_ave"    />
        <result property="loanAve"    column="loan_ave"    />
        <result property="isPh"    column="is_ph"    />
        <result property="isSx"    column="is_sx"    />
        <result property="isYxht"    column="is_yxht"    />
        <result property="isXyk"    column="is_xyk"    />
        <result property="fshl"    column="fshl"    />
        <result property="isSd"    column="is_sd"    />
        <result property="etc"    column="etc"    />
        <result property="dian"    column="dian"    />
        <result property="isBlack"    column="is_black"    />
        <result property="isBad"    column="is_bad"    />
        <result property="shapeId"    column="shape_id"    />
        <result property="opsDept"    column="ops_dept"    />
        <result property="custType"    column="cust_type"    />
    </resultMap>



    <sql id="selectGridShapeCountGongsiVo">
        select dt, shape_type, shape_id, shape_name, grid_id, grid_name, dept_id, dept_name, outlets_id, outlets_name, user_name, cust_num, hq_cur_balance, bz_cur_balance, loan_balance_cny, finance_prod_711_balance, finance_prod_716_balance, loan_year_dailyaverage, htqy_rat, qfcd_rat, tx_rat, bh_rat, yxdfgz_rat, dkdf_rat, dksf_rat, dkshf_rat, pjb_rat, czb_rat, sfb_rat, mrb_rat, szst_rat, kh_rat, gjjsyw_rat, yqjsh_rat, htqy_num, qfcd_num, tx_num, bh_num, yxdfgz_num, ustr_count_per_m, ustr_bal_m, dkdf_num, dksf_num, dkshf_num, pjb_num, czb_num, sfb_num, mrb_num, szst_num, kh_num, gjjsyw_num, yqjsh_num, ops_dept from grid_shape_count_gongsi
    </sql>

    <select id="selectGridShapeCountGongsiList" parameterType="GridShapeCountGongsi" resultMap="GridShapeCountGongsiResult">
        select dt, shape_type, shape_id, shape_name, grid_id, grid_name, dept_id, dept_name, outlets_id, outlets_name, user_name, cust_num, hq_cur_balance, bz_cur_balance, loan_balance_cny, finance_prod_711_balance, finance_prod_716_balance, loan_year_dailyaverage, htqy_rat, qfcd_rat, tx_rat, bh_rat, yxdfgz_rat, dkdf_rat, dksf_rat, dkshf_rat, pjb_rat, czb_rat, sfb_rat, mrb_rat, szst_rat, kh_rat, gjjsyw_rat, yqjsh_rat, htqy_num, qfcd_num, tx_num, bh_num, yxdfgz_num, ustr_count_per_m, ustr_bal_m, dkdf_num, dksf_num, dkshf_num, pjb_num, czb_num, sfb_num, mrb_num, szst_num, kh_num, gjjsyw_num, yqjsh_num, ops_dept,
        zf_365cnt, zf_180cnt, zf_90cnt, zf_30cnt, zf_365rt, zf_180rt, zf_90rt, zf_30rt
        from grid_shape_count_gongsi
        <where>
            <if test=" dt != null  and dt != ''">and dt = #{dt}</if>
            <if test=" shapeName != null  and shapeName != ''">and shape_name like concat('%',concat(#{shapeName},'%'))</if>
            <if test=" shapeType != null  and shapeType != ''">and shape_type like concat('%',concat(#{shapeType},'%'))</if>
            <if test=" gridName != null  and gridName != ''">and grid_name like concat('%',concat(#{gridName},'%'))</if>
            <if test=" isBranch == true">and dept_id like concat('%',concat(#{deptId},'%'))</if>
            <if test=" isOutlet == true">and outlets_id like concat('%',concat(#{deptId},'%'))</if>
            <if test=" isManager == true">and user_name like concat('%',concat(#{userName},'%'))</if>
        </where>
    </select>


    <select id="selectGridShapeCountLingshouList" parameterType="GridShapeCountLingshou" resultMap="GridShapeCountLingshouResult">
        select dt, shape_type, shape_id, shape_name, grid_id, grid_name, dept_id, dept_name, outlets_id, outlets_name, user_name, cust_num, cur_bal_d, cur_bal_t, bal_loan, cur_bal_5_bad, cur_d_ave, cur_t_ave, loan_ave, ph_rat, sx_rat, yxht_rat, xyk_rat, fshl_rat, sd_rat, etc_rat, dian_rat, black_rat, bad_rat, bad_bal_rat, ph_num, sx_num, yxht_num, xyk_num, fshl_num, sd_num, etc_num, dian_num, black_num, bad_num, ops_dept,
        zf_365cnt, zf_180cnt, zf_90cnt, zf_30cnt, zf_365rt, zf_180rt, zf_90rt, zf_30rt
        from grid_shape_count_lingshou
        <where>
            <if test=" dt != null  and dt != ''">and dt = #{dt}</if>
            <if test=" shapeName != null  and shapeName != ''">and shape_name like concat('%',concat(#{shapeName},'%'))</if>
            <if test=" shapeType != null  and shapeType != ''">and shape_type like concat('%',concat(#{shapeType},'%'))</if>
            <if test=" gridName != null  and gridName != ''">and grid_name like concat('%',concat(#{gridName},'%'))</if>
            <if test=" isBranch == true">and dept_id like concat('%',concat(#{deptId},'%'))</if>
            <if test=" isOutlet == true">and outlets_id like concat('%',concat(#{deptId},'%'))</if>
            <if test=" isManager == true">and user_name like concat('%',concat(#{userName},'%'))</if>
        </where>
    </select>

    <select id="selectGridShapeCountgsCustList" parameterType="GridShapeCustGongsi" resultMap="GridShapeCustGongsiResult">
        select cust_name, social_credit_code, cust_isn, hq_cur_balance, bz_cur_balance, is_credit, loan_balance_cny, loan_year_dailyaverage, is_htqy, finance_prod_716_open_flag, finance_prod_716_balance, finance_prod_711_open_flag, finance_prod_711_balance, intl_bussiness_jcbh_open_flag, is_ustr, ustr_count_per_m, ustr_bal_m, eleccharge_sign_flag, watercharge_sign_flag, taxdeduction_sign_flag, pjb, czb, sfb, mrb, szst, is_open_sts, intl_bussiness_open_flag, intl_bussiness_325_open_flag, shape_id, ops_dept, cust_type,
        is_365zf, is_180zf, is_90zf, is_30zf
        from grid_shape_cust_gongsi
        where FIND_IN_SET(#{shapeId}, shape_id) > 0
        <if test=" dt != null  and dt != ''">and dt = #{dt}</if>
        <if test=" custName != null  and custName != ''">and cust_name like concat('%',concat(#{custName},'%'))</if>
        <if test=" socialCreditCode != null  and socialCreditCode != ''">and social_credit_code like concat('%',concat(#{socialCreditCode},'%'))</if>
    </select>

    <select id="selectGridShapeCountlsCustList" parameterType="GridShapeCustLingshou" resultMap="GridShapeCustLingshouResult">
        select cust_name, cust_idc, cust_isn, cur_bal_d, cur_bal_t, bal_loan, cur_bal_5_bad, cur_d_ave, cur_t_ave, loan_ave, is_ph, is_sx, is_yxht, is_xyk, fshl, is_sd, etc, dian, is_black, is_bad, shape_id, ops_dept, cust_type,
        is_365zf, is_180zf, is_90zf, is_30zf
        from grid_shape_cust_lingshou
        where FIND_IN_SET(#{shapeId}, shape_id) > 0
        <if test=" dt != null  and dt != ''">and dt = #{dt}</if>
        <if test=" custName != null  and custName != ''">and cust_name like concat('%',concat(#{custName},'%'))</if>
        <if test=" custIdc != null  and custIdc != ''">and cust_idc like concat('%',concat(#{custIdc},'%'))</if>
    </select>





    <select id="selectGridShapeCountGongsiByDt" parameterType="String" resultMap="GridShapeCountGongsiResult">
        <include refid="selectGridShapeCountGongsiVo"/>
        where dt = #{dt}
    </select>

    <insert id="insertGridShapeCountGongsi" parameterType="GridShapeCountGongsi">
        insert into grid_shape_count_gongsi
        <trim prefix="(" suffix=")" suffixOverrides=",">
            <if test="dt != null">dt,</if>
            <if test="shapeType != null">shape_type,</if>
            <if test="shapeId != null">shape_id,</if>
            <if test="shapeName != null">shape_name,</if>
            <if test="gridId != null">grid_id,</if>
            <if test="gridName != null">grid_name,</if>
            <if test="deptId != null">dept_id,</if>
            <if test="deptName != null">dept_name,</if>
            <if test="outletsId != null">outlets_id,</if>
            <if test="outletsName != null">outlets_name,</if>
            <if test="userName != null">user_name,</if>
            <if test="custNum != null">cust_num,</if>
            <if test="hqCurBalance != null">hq_cur_balance,</if>
            <if test="bzCurBalance != null">bz_cur_balance,</if>
            <if test="loanBalanceCny != null">loan_balance_cny,</if>
            <if test="financeProd711Balance != null">finance_prod_711_balance,</if>
            <if test="financeProd716Balance != null">finance_prod_716_balance,</if>
            <if test="loanYearDailyaverage != null">loan_year_dailyaverage,</if>
            <if test="htqyRat != null">htqy_rat,</if>
            <if test="qfcdRat != null">qfcd_rat,</if>
            <if test="txRat != null">tx_rat,</if>
            <if test="bhRat != null">bh_rat,</if>
            <if test="yxdfgzRat != null">yxdfgz_rat,</if>
            <if test="dkdfRat != null">dkdf_rat,</if>
            <if test="dksfRat != null">dksf_rat,</if>
            <if test="dkshfRat != null">dkshf_rat,</if>
            <if test="pjbRat != null">pjb_rat,</if>
            <if test="czbRat != null">czb_rat,</if>
            <if test="sfbRat != null">sfb_rat,</if>
            <if test="mrbRat != null">mrb_rat,</if>
            <if test="szstRat != null">szst_rat,</if>
            <if test="khRat != null">kh_rat,</if>
            <if test="gjjsywRat != null">gjjsyw_rat,</if>
            <if test="yqjshRat != null">yqjsh_rat,</if>
            <if test="htqyNum != null">htqy_num,</if>
            <if test="qfcdNum != null">qfcd_num,</if>
            <if test="txNum != null">tx_num,</if>
            <if test="bhNum != null">bh_num,</if>
            <if test="yxdfgzNum != null">yxdfgz_num,</if>
            <if test="ustrCountPerM != null">ustr_count_per_m,</if>
            <if test="ustrBalM != null">ustr_bal_m,</if>
            <if test="dkdfNum != null">dkdf_num,</if>
            <if test="dksfNum != null">dksf_num,</if>
            <if test="dkshfNum != null">dkshf_num,</if>
            <if test="pjbNum != null">pjb_num,</if>
            <if test="czbNum != null">czb_num,</if>
            <if test="sfbNum != null">sfb_num,</if>
            <if test="mrbNum != null">mrb_num,</if>
            <if test="szstNum != null">szst_num,</if>
            <if test="khNum != null">kh_num,</if>
            <if test="gjjsywNum != null">gjjsyw_num,</if>
            <if test="yqjshNum != null">yqjsh_num,</if>
            <if test="opsDept != null">ops_dept,</if>
        </trim>
        <trim prefix="values (" suffix=")" suffixOverrides=",">
            <if test="dt != null">#{dt},</if>
            <if test="shapeType != null">#{shapeType},</if>
            <if test="shapeId != null">#{shapeId},</if>
            <if test="shapeName != null">#{shapeName},</if>
            <if test="gridId != null">#{gridId},</if>
            <if test="gridName != null">#{gridName},</if>
            <if test="deptId != null">#{deptId},</if>
            <if test="deptName != null">#{deptName},</if>
            <if test="outletsId != null">#{outletsId},</if>
            <if test="outletsName != null">#{outletsName},</if>
            <if test="userName != null">#{userName},</if>
            <if test="custNum != null">#{custNum},</if>
            <if test="hqCurBalance != null">#{hqCurBalance},</if>
            <if test="bzCurBalance != null">#{bzCurBalance},</if>
            <if test="loanBalanceCny != null">#{loanBalanceCny},</if>
            <if test="financeProd711Balance != null">#{financeProd711Balance},</if>
            <if test="financeProd716Balance != null">#{financeProd716Balance},</if>
            <if test="loanYearDailyaverage != null">#{loanYearDailyaverage},</if>
            <if test="htqyRat != null">#{htqyRat},</if>
            <if test="qfcdRat != null">#{qfcdRat},</if>
            <if test="txRat != null">#{txRat},</if>
            <if test="bhRat != null">#{bhRat},</if>
            <if test="yxdfgzRat != null">#{yxdfgzRat},</if>
            <if test="dkdfRat != null">#{dkdfRat},</if>
            <if test="dksfRat != null">#{dksfRat},</if>
            <if test="dkshfRat != null">#{dkshfRat},</if>
            <if test="pjbRat != null">#{pjbRat},</if>
            <if test="czbRat != null">#{czbRat},</if>
            <if test="sfbRat != null">#{sfbRat},</if>
            <if test="mrbRat != null">#{mrbRat},</if>
            <if test="szstRat != null">#{szstRat},</if>
            <if test="khRat != null">#{khRat},</if>
            <if test="gjjsywRat != null">#{gjjsywRat},</if>
            <if test="yqjshRat != null">#{yqjshRat},</if>
            <if test="htqyNum != null">#{htqyNum},</if>
            <if test="qfcdNum != null">#{qfcdNum},</if>
            <if test="txNum != null">#{txNum},</if>
            <if test="bhNum != null">#{bhNum},</if>
            <if test="yxdfgzNum != null">#{yxdfgzNum},</if>
            <if test="ustrCountPerM != null">#{ustrCountPerM},</if>
            <if test="ustrBalM != null">#{ustrBalM},</if>
            <if test="dkdfNum != null">#{dkdfNum},</if>
            <if test="dksfNum != null">#{dksfNum},</if>
            <if test="dkshfNum != null">#{dkshfNum},</if>
            <if test="pjbNum != null">#{pjbNum},</if>
            <if test="czbNum != null">#{czbNum},</if>
            <if test="sfbNum != null">#{sfbNum},</if>
            <if test="mrbNum != null">#{mrbNum},</if>
            <if test="szstNum != null">#{szstNum},</if>
            <if test="khNum != null">#{khNum},</if>
            <if test="gjjsywNum != null">#{gjjsywNum},</if>
            <if test="yqjshNum != null">#{yqjshNum},</if>
            <if test="opsDept != null">#{opsDept},</if>
        </trim>
    </insert>

    <update id="updateGridShapeCountGongsi" parameterType="GridShapeCountGongsi">
        update grid_shape_count_gongsi
        <trim prefix="SET" suffixOverrides=",">
            <if test="shapeType != null">shape_type = #{shapeType},</if>
            <if test="shapeId != null">shape_id = #{shapeId},</if>
            <if test="shapeName != null">shape_name = #{shapeName},</if>
            <if test="gridId != null">grid_id = #{gridId},</if>
            <if test="gridName != null">grid_name = #{gridName},</if>
            <if test="deptId != null">dept_id = #{deptId},</if>
            <if test="deptName != null">dept_name = #{deptName},</if>
            <if test="outletsId != null">outlets_id = #{outletsId},</if>
            <if test="outletsName != null">outlets_name = #{outletsName},</if>
            <if test="userName != null">user_name = #{userName},</if>
            <if test="custNum != null">cust_num = #{custNum},</if>
            <if test="hqCurBalance != null">hq_cur_balance = #{hqCurBalance},</if>
            <if test="bzCurBalance != null">bz_cur_balance = #{bzCurBalance},</if>
            <if test="loanBalanceCny != null">loan_balance_cny = #{loanBalanceCny},</if>
            <if test="financeProd711Balance != null">finance_prod_711_balance = #{financeProd711Balance},</if>
            <if test="financeProd716Balance != null">finance_prod_716_balance = #{financeProd716Balance},</if>
            <if test="loanYearDailyaverage != null">loan_year_dailyaverage = #{loanYearDailyaverage},</if>
            <if test="htqyRat != null">htqy_rat = #{htqyRat},</if>
            <if test="qfcdRat != null">qfcd_rat = #{qfcdRat},</if>
            <if test="txRat != null">tx_rat = #{txRat},</if>
            <if test="bhRat != null">bh_rat = #{bhRat},</if>
            <if test="yxdfgzRat != null">yxdfgz_rat = #{yxdfgzRat},</if>
            <if test="dkdfRat != null">dkdf_rat = #{dkdfRat},</if>
            <if test="dksfRat != null">dksf_rat = #{dksfRat},</if>
            <if test="dkshfRat != null">dkshf_rat = #{dkshfRat},</if>
            <if test="pjbRat != null">pjb_rat = #{pjbRat},</if>
            <if test="czbRat != null">czb_rat = #{czbRat},</if>
            <if test="sfbRat != null">sfb_rat = #{sfbRat},</if>
            <if test="mrbRat != null">mrb_rat = #{mrbRat},</if>
            <if test="szstRat != null">szst_rat = #{szstRat},</if>
            <if test="khRat != null">kh_rat = #{khRat},</if>
            <if test="gjjsywRat != null">gjjsyw_rat = #{gjjsywRat},</if>
            <if test="yqjshRat != null">yqjsh_rat = #{yqjshRat},</if>
            <if test="htqyNum != null">htqy_num = #{htqyNum},</if>
            <if test="qfcdNum != null">qfcd_num = #{qfcdNum},</if>
            <if test="txNum != null">tx_num = #{txNum},</if>
            <if test="bhNum != null">bh_num = #{bhNum},</if>
            <if test="yxdfgzNum != null">yxdfgz_num = #{yxdfgzNum},</if>
            <if test="ustrCountPerM != null">ustr_count_per_m = #{ustrCountPerM},</if>
            <if test="ustrBalM != null">ustr_bal_m = #{ustrBalM},</if>
            <if test="dkdfNum != null">dkdf_num = #{dkdfNum},</if>
            <if test="dksfNum != null">dksf_num = #{dksfNum},</if>
            <if test="dkshfNum != null">dkshf_num = #{dkshfNum},</if>
            <if test="pjbNum != null">pjb_num = #{pjbNum},</if>
            <if test="czbNum != null">czb_num = #{czbNum},</if>
            <if test="sfbNum != null">sfb_num = #{sfbNum},</if>
            <if test="mrbNum != null">mrb_num = #{mrbNum},</if>
            <if test="szstNum != null">szst_num = #{szstNum},</if>
            <if test="khNum != null">kh_num = #{khNum},</if>
            <if test="gjjsywNum != null">gjjsyw_num = #{gjjsywNum},</if>
            <if test="yqjshNum != null">yqjsh_num = #{yqjshNum},</if>
            <if test="opsDept != null">ops_dept = #{opsDept},</if>
        </trim>
        where dt = #{dt}
    </update>

    <delete id="deleteGridShapeCountGongsiByDt" parameterType="String">
        delete from grid_shape_count_gongsi where dt = #{dt}
    </delete>

    <delete id="deleteGridShapeCountGongsiByDts" parameterType="String">
        delete from grid_shape_count_gongsi where dt in
        <foreach item="dt" collection="array" open="(" separator="," close=")">
            #{dt}
        </foreach>
    </delete>
</mapper>