BusinessAnalyzeMapper.xml 35 KB
<?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.chinagas.modules.insight.mapper.BusinessAnalyzeMapper">
    
    <resultMap type="com.chinagas.modules.insight.domian.BusinessAnalyze" id="BusinessAnalyzeResult">
        <result property="id"    column="id"    />
        <result property="reportNo"    column="report_no"    />
        <result property="fiscalYear"    column="fiscal_year"    />
        <result property="cityNewInstalled"    column="city_new_installed"    />
        <result property="auctionArea"    column="auction_area"    />
        <result property="newStartArea"    column="new_start_area"    />
        <result property="newCompletedArea"    column="new_completed_area"    />
        <result property="cityOldHouseholdSituation"    column="city_old_household_situation"    />
        <result property="cityResidentNumber"    column="city_resident_number"    />
        <result property="cityResidentHousehold"    column="city_resident_household"    />
        <result property="cityUseHousehold"    column="city_use_household"    />
        <result property="continuousUseHousehold"    column="continuous_use_household"    />
        <result property="uninstallHousehold"    column="uninstall_household"    />
        <result property="receivableHousehold"    column="receivable_household"    />
        <result property="remainHousehold"    column="remain_household"    />
        <result property="confirmInstallNumber"    column="confirm_install_number"    />
        <result property="newRefundHousehold"    column="new_refund_household"    />
        <result property="oldRefundAmount"    column="old_refund_amount"    />
        <result property="cityOldUserSituation"    column="city_old_user_situation"    />
        <result property="coveredOldHousehold"    column="covered_old_household"    />
        <result property="coveredSignedHousehold"    column="covered_signed_household"    />
        <result property="coveredConfirmHousehold"    column="covered_confirm_household"    />
        <result property="coveredUnexploitableHousehold"    column="covered_unexploitable_household"    />
        <result property="coveredExploitableHousehold"    column="covered_exploitable_household"    />
        <result property="uncoveredOldHousehold"    column="uncovered_old_household"    />
        <result property="uncoveredSignedHousehold"    column="uncovered_signed_household"    />
        <result property="uncoveredConfirmHousehold"    column="uncovered_confirm_household"    />
        <result property="coveredTownsSituation"    column="covered_towns_situation"    />
        <result property="coveredVillageSituation"    column="covered_village_situation"    />
        <result property="uncoveredTownsSituation"    column="uncovered_towns_situation"    />
        <result property="uncoveredVillageSituation"    column="uncovered_village_situation"    />
        <result property="totalSituation"    column="total_situation"    />
        <result property="villageGasInfo"    column="village_gas_info"    />
        <result property="townsNewUserInfo"    column="towns_new_user_info"    />
        <result property="townsGasCoal"    column="towns_gas_coal"    />
        <result property="industryUser"    column="industry_user"    />
        <result property="industryCommerceUser"    column="industry_commerce_user"    />
        <result property="commerceCoalGas"    column="commerce_coal_gas"    />
        <result property="installPrice"    column="install_price"    />
        <result property="baseSales"    column="base_sales"    />
        <result property="useSalesGrowth"    column="use_sales_growth"    />
        <result property="signSalesGrowth"    column="sign_sales_growth"    />
        <result property="predictSalesGrowth"    column="predict_sales_growth"    />
        <result property="predictSalesTotal"    column="predict_sales_total"    />
        <result property="otherInfo"    column="other_info"    />
        <result property="carGasInfo"    column="car_gas_info"    />
        <result property="gasTrade"    column="gas_trade"    />
        <result property="priceSurvey"    column="price_survey"    />
        <result property="outstandingPaymentNumber"    column="outstanding_payment_number"    />
        <result property="newMarketResident"    column="new_market_resident"    />
        <result property="sysCtime"    column="sys_ctime"    />
        <result property="sysUtime"    column="sys_utime"    />
        <result property="createBy"    column="create_by"    />
        <result property="updateBy"    column="update_by"    />
        <result property="isDelete"    column="is_delete"    />
        <result property="householdNumberSubtotalBefore"    column="household_number_subtotal_before"    />
        <result property="predictInstallSubtotalBefore"    column="predict_install_subtotal_before"    />
        <result property="householdNumberSubtotal"    column="household_number_subtotal"    />
        <result property="predictInstallSubtotal"    column="predict_install_subtotal"    />
        <result property="householdNumberTotal"    column="household_number_total"    />
        <result property="predictInstallTotal"    column="predict_install_total"    />
        <result property="currentInstallSubtotal"    column="current_install_subtotal"    />
        <result property="afterInstallSubtotal"    column="after_install_subtotal"    />
        <result property="lastInstallSubtotal"    column="last_install_subtotal"    />
        <result property="installTotal"    column="install_total"    />
    </resultMap>

    <sql id="selectBusinessAnalyzeVo">
        select id, report_no, fiscal_year, city_new_installed, auction_area, new_start_area, new_completed_area, city_old_household_situation, city_resident_number,
               city_resident_household, city_use_household, continuous_use_household, uninstall_household, receivable_household, remain_household, confirm_install_number,
               new_refund_household, old_refund_amount, city_old_user_situation, covered_old_household, covered_signed_household, covered_confirm_household,
               covered_unexploitable_household, covered_exploitable_household, uncovered_old_household, uncovered_signed_household, uncovered_confirm_household,
               covered_towns_situation, covered_village_situation, uncovered_towns_situation, uncovered_village_situation, total_situation, village_gas_info,
               towns_new_user_info, towns_gas_coal, industry_user, industry_commerce_user, commerce_coal_gas, install_price, base_sales, use_sales_growth,
               sign_sales_growth, predict_sales_growth, predict_sales_total, other_info, car_gas_info, gas_trade, price_survey, outstanding_payment_number,
               sys_ctime, sys_utime, create_by, update_by, is_delete, household_number_subtotal_before, predict_install_subtotal_before, household_number_subtotal,
               predict_install_subtotal, household_number_total, predict_install_total,current_install_subtotal, after_install_subtotal, last_install_subtotal,
               install_total,new_market_resident from business_analyze
    </sql>

    <select id="selectBusinessAnalyzeList" parameterType="com.chinagas.modules.insight.domian.BusinessAnalyze" resultMap="BusinessAnalyzeResult">
        <include refid="selectBusinessAnalyzeVo"/>
        <where>  
            <if test="reportNo != null  and reportNo != ''"> and report_no = #{reportNo}</if>
            <if test="fiscalYear != null "> and fiscal_year = #{fiscalYear}</if>
            <if test="cityNewInstalled != null  and cityNewInstalled != ''"> and city_new_installed = #{cityNewInstalled}</if>
            <if test="auctionArea != null  and auctionArea != ''"> and auction_area = #{auctionArea}</if>
            <if test="newStartArea != null  and newStartArea != ''"> and new_start_area = #{newStartArea}</if>
            <if test="newCompletedArea != null  and newCompletedArea != ''"> and new_completed_area = #{newCompletedArea}</if>
            <if test="cityOldHouseholdSituation != null  and cityOldHouseholdSituation != ''"> and city_old_household_situation = #{cityOldHouseholdSituation}</if>
            <if test="cityResidentNumber != null  and cityResidentNumber != ''"> and city_resident_number = #{cityResidentNumber}</if>
            <if test="cityResidentHousehold != null  and cityResidentHousehold != ''"> and city_resident_household = #{cityResidentHousehold}</if>
            <if test="cityUseHousehold != null  and cityUseHousehold != ''"> and city_use_household = #{cityUseHousehold}</if>
            <if test="continuousUseHousehold != null  and continuousUseHousehold != ''"> and continuous_use_household = #{continuousUseHousehold}</if>
            <if test="uninstallHousehold != null  and uninstallHousehold != ''"> and uninstall_household = #{uninstallHousehold}</if>
            <if test="receivableHousehold != null  and receivableHousehold != ''"> and receivable_household = #{receivableHousehold}</if>
            <if test="remainHousehold != null  and remainHousehold != ''"> and remain_household = #{remainHousehold}</if>
            <if test="confirmInstallNumber != null  and confirmInstallNumber != ''"> and confirm_install_number = #{confirmInstallNumber}</if>
            <if test="newRefundHousehold != null  and newRefundHousehold != ''"> and new_refund_household = #{newRefundHousehold}</if>
            <if test="oldRefundAmount != null  and oldRefundAmount != ''"> and old_refund_amount = #{oldRefundAmount}</if>
            <if test="cityOldUserSituation != null  and cityOldUserSituation != ''"> and city_old_user_situation = #{cityOldUserSituation}</if>
            <if test="coveredOldHousehold != null "> and covered_old_household = #{coveredOldHousehold}</if>
            <if test="coveredSignedHousehold != null "> and covered_signed_household = #{coveredSignedHousehold}</if>
            <if test="coveredConfirmHousehold != null "> and covered_confirm_household = #{coveredConfirmHousehold}</if>
            <if test="coveredUnexploitableHousehold != null "> and covered_unexploitable_household = #{coveredUnexploitableHousehold}</if>
            <if test="coveredExploitableHousehold != null "> and covered_exploitable_household = #{coveredExploitableHousehold}</if>
            <if test="uncoveredOldHousehold != null "> and uncovered_old_household = #{uncoveredOldHousehold}</if>
            <if test="uncoveredSignedHousehold != null "> and uncovered_signed_household = #{uncoveredSignedHousehold}</if>
            <if test="uncoveredConfirmHousehold != null "> and uncovered_confirm_household = #{uncoveredConfirmHousehold}</if>
            <if test="coveredTownsSituation != null  and coveredTownsSituation != ''"> and covered_towns_situation = #{coveredTownsSituation}</if>
            <if test="coveredVillageSituation != null  and coveredVillageSituation != ''"> and covered_village_situation = #{coveredVillageSituation}</if>
            <if test="uncoveredTownsSituation != null  and uncoveredTownsSituation != ''"> and uncovered_towns_situation = #{uncoveredTownsSituation}</if>
            <if test="uncoveredVillageSituation != null  and uncoveredVillageSituation != ''"> and uncovered_village_situation = #{uncoveredVillageSituation}</if>
            <if test="totalSituation != null  and totalSituation != ''"> and total_situation = #{totalSituation}</if>
            <if test="villageGasInfo != null  and villageGasInfo != ''"> and village_gas_info = #{villageGasInfo}</if>
            <if test="townsNewUserInfo != null  and townsNewUserInfo != ''"> and towns_new_user_info = #{townsNewUserInfo}</if>
            <if test="townsGasCoal != null  and townsGasCoal != ''"> and towns_gas_coal = #{townsGasCoal}</if>
            <if test="industryUser != null  and industryUser != ''"> and industry_user = #{industryUser}</if>
            <if test="industryCommerceUser != null  and industryCommerceUser != ''"> and industry_commerce_user = #{industryCommerceUser}</if>
            <if test="commerceCoalGas != null  and commerceCoalGas != ''"> and commerce_coal_gas = #{commerceCoalGas}</if>
            <if test="installPrice != null  and installPrice != ''"> and install_price = #{installPrice}</if>
            <if test="baseSales != null  and baseSales != ''"> and base_sales = #{baseSales}</if>
            <if test="useSalesGrowth != null  and useSalesGrowth != ''"> and use_sales_growth = #{useSalesGrowth}</if>
            <if test="signSalesGrowth != null  and signSalesGrowth != ''"> and sign_sales_growth = #{signSalesGrowth}</if>
            <if test="predictSalesGrowth != null  and predictSalesGrowth != ''"> and predict_sales_growth = #{predictSalesGrowth}</if>
            <if test="predictSalesTotal != null  and predictSalesTotal != ''"> and predict_sales_total = #{predictSalesTotal}</if>
            <if test="otherInfo != null  and otherInfo != ''"> and other_info = #{otherInfo}</if>
            <if test="carGasInfo != null  and carGasInfo != ''"> and car_gas_info = #{carGasInfo}</if>
            <if test="gasTrade != null  and gasTrade != ''"> and gas_trade = #{gasTrade}</if>
            <if test="priceSurvey != null  and priceSurvey != ''"> and price_survey = #{priceSurvey}</if>
            <if test="outstandingPaymentNumber != null  and outstandingPaymentNumber != ''"> and outstanding_payment_number = #{outstandingPaymentNumber}</if>
            <if test="newMarketResident != null  and newMarketResident != ''"> and new_market_resident = #{newMarketResident}</if>
            <if test="sysCtime != null "> and sys_ctime = #{sysCtime}</if>
            <if test="sysUtime != null "> and sys_utime = #{sysUtime}</if>
            <if test="householdNumberSubtotalBefore != null "> and household_number_subtotal_before = #{householdNumberSubtotalBefore}</if>
            <if test="predictInstallSubtotalBefore != null "> and predict_install_subtotal_before = #{predictInstallSubtotalBefore}</if>
            <if test="householdNumberSubtotal != null "> and household_number_subtotal = #{householdNumberSubtotal}</if>
            <if test="predictInstallSubtotal != null "> and predict_install_subtotal = #{predictInstallSubtotal}</if>
            <if test="householdNumberTotal != null "> and household_number_total = #{householdNumberTotal}</if>
            <if test="predictInstallTotal != null "> and predict_install_total = #{predictInstallTotal}</if>
            <if test="currentInstallSubtotal != null "> and current_install_subtotal = #{currentInstallSubtotal}</if>
            <if test="afterInstallSubtotal != null "> and after_install_subtotal = #{afterInstallSubtotal}</if>
            <if test="lastInstallSubtotal != null "> and last_install_subtotal = #{lastInstallSubtotal}</if>
            <if test="installTotal != null "> and install_total = #{installTotal}</if>
            and is_delete = 0
        </where>
    </select>
    
    <select id="selectBusinessAnalyzeById" resultMap="BusinessAnalyzeResult">
        <include refid="selectBusinessAnalyzeVo"/>
        where report_no = #{reportNo}
    </select>
        
    <insert id="insertBusinessAnalyze" parameterType="com.chinagas.modules.insight.domian.BusinessAnalyze">
        insert into business_analyze
        <trim prefix="(" suffix=")" suffixOverrides=",">
            <if test="id != null">id,</if>
            <if test="reportNo != null and reportNo != ''">report_no,</if>
            <if test="fiscalYear != null">fiscal_year,</if>
            <if test="cityNewInstalled != null and cityNewInstalled != ''">city_new_installed,</if>
            <if test="auctionArea != null and auctionArea != ''">auction_area,</if>
            <if test="newStartArea != null and newStartArea != ''">new_start_area,</if>
            <if test="newCompletedArea != null and newCompletedArea != ''">new_completed_area,</if>
            <if test="cityOldHouseholdSituation != null and cityOldHouseholdSituation != ''">city_old_household_situation,</if>
            <if test="cityResidentNumber != null and cityResidentNumber != ''">city_resident_number,</if>
            <if test="cityResidentHousehold != null and cityResidentHousehold != ''">city_resident_household,</if>
            <if test="cityUseHousehold != null and cityUseHousehold != ''">city_use_household,</if>
            <if test="continuousUseHousehold != null and continuousUseHousehold != ''">continuous_use_household,</if>
            <if test="uninstallHousehold != null and uninstallHousehold != ''">uninstall_household,</if>
            <if test="receivableHousehold != null and receivableHousehold != ''">receivable_household,</if>
            <if test="remainHousehold != null and remainHousehold != ''">remain_household,</if>
            <if test="confirmInstallNumber != null and confirmInstallNumber != ''">confirm_install_number,</if>
            <if test="newRefundHousehold != null and newRefundHousehold != ''">new_refund_household,</if>
            <if test="oldRefundAmount != null and oldRefundAmount != ''">old_refund_amount,</if>
            <if test="cityOldUserSituation != null and cityOldUserSituation != ''">city_old_user_situation,</if>
            <if test="coveredOldHousehold != null">covered_old_household,</if>
            <if test="coveredSignedHousehold != null">covered_signed_household,</if>
            <if test="coveredConfirmHousehold != null">covered_confirm_household,</if>
            <if test="coveredUnexploitableHousehold != null">covered_unexploitable_household,</if>
            <if test="coveredExploitableHousehold != null">covered_exploitable_household,</if>
            <if test="uncoveredOldHousehold != null">uncovered_old_household,</if>
            <if test="uncoveredSignedHousehold != null">uncovered_signed_household,</if>
            <if test="uncoveredConfirmHousehold != null">uncovered_confirm_household,</if>
            <if test="coveredTownsSituation != null and coveredTownsSituation != ''">covered_towns_situation,</if>
            <if test="coveredVillageSituation != null and coveredVillageSituation != ''">covered_village_situation,</if>
            <if test="uncoveredTownsSituation != null and uncoveredTownsSituation != ''">uncovered_towns_situation,</if>
            <if test="uncoveredVillageSituation != null and uncoveredVillageSituation != ''">uncovered_village_situation,</if>
            <if test="totalSituation != null and totalSituation != ''">total_situation,</if>
            <if test="villageGasInfo != null and villageGasInfo != ''">village_gas_info,</if>
            <if test="townsNewUserInfo != null and townsNewUserInfo != ''">towns_new_user_info,</if>
            <if test="townsGasCoal != null and townsGasCoal != ''">towns_gas_coal,</if>
            <if test="industryUser != null and industryUser != ''">industry_user,</if>
            <if test="industryCommerceUser != null and industryCommerceUser != ''">industry_commerce_user,</if>
            <if test="commerceCoalGas != null and commerceCoalGas != ''">commerce_coal_gas,</if>
            <if test="installPrice != null and installPrice != ''">install_price,</if>
            <if test="baseSales != null and baseSales != ''">base_sales,</if>
            <if test="useSalesGrowth != null and useSalesGrowth != ''">use_sales_growth,</if>
            <if test="signSalesGrowth != null and signSalesGrowth != ''">sign_sales_growth,</if>
            <if test="predictSalesGrowth != null and predictSalesGrowth != ''">predict_sales_growth,</if>
            <if test="predictSalesTotal != null and predictSalesTotal != ''">predict_sales_total,</if>
            <if test="otherInfo != null and otherInfo != ''">other_info,</if>
            <if test="carGasInfo != null and carGasInfo != ''">car_gas_info,</if>
            <if test="gasTrade != null and gasTrade != ''">gas_trade,</if>
            <if test="priceSurvey != null and priceSurvey != ''">price_survey,</if>
            <if test="outstandingPaymentNumber != null and outstandingPaymentNumber != ''">outstanding_payment_number,</if>
            <if test="newMarketResident != null and newMarketResident != ''">new_market_resident,</if>
            <if test="sysCtime != null">sys_ctime,</if>
            <if test="sysUtime != null">sys_utime,</if>
            <if test="createBy != null and createBy != ''">create_by,</if>
            <if test="updateBy != null and updateBy != ''">update_by,</if>
            <if test="isDelete != null">is_delete,</if>
            <if test="householdNumberSubtotalBefore != null">household_number_subtotal_before,</if>
            <if test="predictInstallSubtotalBefore != null">predict_install_subtotal_before,</if>
            <if test="householdNumberSubtotal != null">household_number_subtotal,</if>
            <if test="predictInstallSubtotal != null">predict_install_subtotal,</if>
            <if test="householdNumberTotal != null">household_number_total,</if>
            <if test="predictInstallTotal != null">predict_install_total,</if>
            <if test="currentInstallSubtotal != null">current_install_subtotal,</if>
            <if test="afterInstallSubtotal != null">after_install_subtotal,</if>
            <if test="lastInstallSubtotal != null">last_install_subtotal,</if>
            <if test="installTotal != null">install_total,</if>
         </trim>
        <trim prefix="values (" suffix=")" suffixOverrides=",">
            <if test="id != null">#{id},</if>
            <if test="reportNo != null and reportNo != ''">#{reportNo},</if>
            <if test="fiscalYear != null">#{fiscalYear},</if>
            <if test="cityNewInstalled != null and cityNewInstalled != ''">#{cityNewInstalled},</if>
            <if test="auctionArea != null and auctionArea != ''">#{auctionArea},</if>
            <if test="newStartArea != null and newStartArea != ''">#{newStartArea},</if>
            <if test="newCompletedArea != null and newCompletedArea != ''">#{newCompletedArea},</if>
            <if test="cityOldHouseholdSituation != null and cityOldHouseholdSituation != ''">#{cityOldHouseholdSituation},</if>
            <if test="cityResidentNumber != null and cityResidentNumber != ''">#{cityResidentNumber},</if>
            <if test="cityResidentHousehold != null and cityResidentHousehold != ''">#{cityResidentHousehold},</if>
            <if test="cityUseHousehold != null and cityUseHousehold != ''">#{cityUseHousehold},</if>
            <if test="continuousUseHousehold != null and continuousUseHousehold != ''">#{continuousUseHousehold},</if>
            <if test="uninstallHousehold != null and uninstallHousehold != ''">#{uninstallHousehold},</if>
            <if test="receivableHousehold != null and receivableHousehold != ''">#{receivableHousehold},</if>
            <if test="remainHousehold != null and remainHousehold != ''">#{remainHousehold},</if>
            <if test="confirmInstallNumber != null and confirmInstallNumber != ''">#{confirmInstallNumber},</if>
            <if test="newRefundHousehold != null and newRefundHousehold != ''">#{newRefundHousehold},</if>
            <if test="oldRefundAmount != null and oldRefundAmount != ''">#{oldRefundAmount},</if>
            <if test="cityOldUserSituation != null and cityOldUserSituation != ''">#{cityOldUserSituation},</if>
            <if test="coveredOldHousehold != null">#{coveredOldHousehold},</if>
            <if test="coveredSignedHousehold != null">#{coveredSignedHousehold},</if>
            <if test="coveredConfirmHousehold != null">#{coveredConfirmHousehold},</if>
            <if test="coveredUnexploitableHousehold != null">#{coveredUnexploitableHousehold},</if>
            <if test="coveredExploitableHousehold != null">#{coveredExploitableHousehold},</if>
            <if test="uncoveredOldHousehold != null">#{uncoveredOldHousehold},</if>
            <if test="uncoveredSignedHousehold != null">#{uncoveredSignedHousehold},</if>
            <if test="uncoveredConfirmHousehold != null">#{uncoveredConfirmHousehold},</if>
            <if test="coveredTownsSituation != null and coveredTownsSituation != ''">#{coveredTownsSituation},</if>
            <if test="coveredVillageSituation != null and coveredVillageSituation != ''">#{coveredVillageSituation},</if>
            <if test="uncoveredTownsSituation != null and uncoveredTownsSituation != ''">#{uncoveredTownsSituation},</if>
            <if test="uncoveredVillageSituation != null and uncoveredVillageSituation != ''">#{uncoveredVillageSituation},</if>
            <if test="totalSituation != null and totalSituation != ''">#{totalSituation},</if>
            <if test="villageGasInfo != null and villageGasInfo != ''">#{villageGasInfo},</if>
            <if test="townsNewUserInfo != null and townsNewUserInfo != ''">#{townsNewUserInfo},</if>
            <if test="townsGasCoal != null and townsGasCoal != ''">#{townsGasCoal},</if>
            <if test="industryUser != null and industryUser != ''">#{industryUser},</if>
            <if test="industryCommerceUser != null and industryCommerceUser != ''">#{industryCommerceUser},</if>
            <if test="commerceCoalGas != null and commerceCoalGas != ''">#{commerceCoalGas},</if>
            <if test="installPrice != null and installPrice != ''">#{installPrice},</if>
            <if test="baseSales != null and baseSales != ''">#{baseSales},</if>
            <if test="useSalesGrowth != null and useSalesGrowth != ''">#{useSalesGrowth},</if>
            <if test="signSalesGrowth != null and signSalesGrowth != ''">#{signSalesGrowth},</if>
            <if test="predictSalesGrowth != null and predictSalesGrowth != ''">#{predictSalesGrowth},</if>
            <if test="predictSalesTotal != null and predictSalesTotal != ''">#{predictSalesTotal},</if>
            <if test="otherInfo != null and otherInfo != ''">#{otherInfo},</if>
            <if test="carGasInfo != null and carGasInfo != ''">#{carGasInfo},</if>
            <if test="gasTrade != null and gasTrade != ''">#{gasTrade},</if>
            <if test="priceSurvey != null and priceSurvey != ''">#{priceSurvey},</if>
            <if test="outstandingPaymentNumber != null and outstandingPaymentNumber != ''">#{outstandingPaymentNumber},</if>
            <if test="newMarketResident != null and newMarketResident != ''">#{newMarketResident},</if>
            <if test="sysCtime != null">#{sysCtime},</if>
            <if test="sysUtime != null">#{sysUtime},</if>
            <if test="createBy != null and createBy != ''">#{createBy},</if>
            <if test="updateBy != null and updateBy != ''">#{updateBy},</if>
            <if test="isDelete != null">#{isDelete},</if>
            <if test="householdNumberSubtotalBefore != null">#{householdNumberSubtotalBefore},</if>
            <if test="predictInstallSubtotalBefore != null">#{predictInstallSubtotalBefore},</if>
            <if test="householdNumberSubtotal != null">#{householdNumberSubtotal},</if>
            <if test="predictInstallSubtotal != null">#{predictInstallSubtotal},</if>
            <if test="householdNumberTotal != null">#{householdNumberTotal},</if>
            <if test="predictInstallTotal != null">#{predictInstallTotal},</if>
            <if test="currentInstallSubtotal != null">#{currentInstallSubtotal},</if>
            <if test="afterInstallSubtotal != null">#{afterInstallSubtotal},</if>
            <if test="lastInstallSubtotal != null">#{lastInstallSubtotal},</if>
            <if test="installTotal != null">#{installTotal},</if>
         </trim>
    </insert>

    <update id="updateBusinessAnalyze" parameterType="com.chinagas.modules.insight.domian.BusinessAnalyze">
        update business_analyze
        <trim prefix="SET" suffixOverrides=",">
            <if test="reportNo != null and reportNo != ''">report_no = #{reportNo},</if>
            <if test="fiscalYear != null">fiscal_year = #{fiscalYear},</if>
            <if test="cityNewInstalled != null and cityNewInstalled != ''">city_new_installed = #{cityNewInstalled},</if>
            <if test="auctionArea != null and auctionArea != ''">auction_area = #{auctionArea},</if>
            <if test="newStartArea != null and newStartArea != ''">new_start_area = #{newStartArea},</if>
            <if test="newCompletedArea != null and newCompletedArea != ''">new_completed_area = #{newCompletedArea},</if>
            <if test="cityOldHouseholdSituation != null and cityOldHouseholdSituation != ''">city_old_household_situation = #{cityOldHouseholdSituation},</if>
            <if test="cityResidentNumber != null and cityResidentNumber != ''">city_resident_number = #{cityResidentNumber},</if>
            <if test="cityResidentHousehold != null and cityResidentHousehold != ''">city_resident_household = #{cityResidentHousehold},</if>
            <if test="cityUseHousehold != null and cityUseHousehold != ''">city_use_household = #{cityUseHousehold},</if>
            <if test="continuousUseHousehold != null and continuousUseHousehold != ''">continuous_use_household = #{continuousUseHousehold},</if>
            <if test="uninstallHousehold != null and uninstallHousehold != ''">uninstall_household = #{uninstallHousehold},</if>
            <if test="receivableHousehold != null and receivableHousehold != ''">receivable_household = #{receivableHousehold},</if>
            <if test="remainHousehold != null and remainHousehold != ''">remain_household = #{remainHousehold},</if>
            <if test="confirmInstallNumber != null and confirmInstallNumber != ''">confirm_install_number = #{confirmInstallNumber},</if>
            <if test="newRefundHousehold != null and newRefundHousehold != ''">new_refund_household = #{newRefundHousehold},</if>
            <if test="oldRefundAmount != null and oldRefundAmount != ''">old_refund_amount = #{oldRefundAmount},</if>
            <if test="cityOldUserSituation != null and cityOldUserSituation != ''">city_old_user_situation = #{cityOldUserSituation},</if>
            <if test="coveredOldHousehold != null">covered_old_household = #{coveredOldHousehold},</if>
            <if test="coveredSignedHousehold != null">covered_signed_household = #{coveredSignedHousehold},</if>
            <if test="coveredConfirmHousehold != null">covered_confirm_household = #{coveredConfirmHousehold},</if>
            <if test="coveredUnexploitableHousehold != null">covered_unexploitable_household = #{coveredUnexploitableHousehold},</if>
            <if test="coveredExploitableHousehold != null">covered_exploitable_household = #{coveredExploitableHousehold},</if>
            <if test="uncoveredOldHousehold != null">uncovered_old_household = #{uncoveredOldHousehold},</if>
            <if test="uncoveredSignedHousehold != null">uncovered_signed_household = #{uncoveredSignedHousehold},</if>
            <if test="uncoveredConfirmHousehold != null">uncovered_confirm_household = #{uncoveredConfirmHousehold},</if>
            <if test="coveredTownsSituation != null and coveredTownsSituation != ''">covered_towns_situation = #{coveredTownsSituation},</if>
            <if test="coveredVillageSituation != null and coveredVillageSituation != ''">covered_village_situation = #{coveredVillageSituation},</if>
            <if test="uncoveredTownsSituation != null and uncoveredTownsSituation != ''">uncovered_towns_situation = #{uncoveredTownsSituation},</if>
            <if test="uncoveredVillageSituation != null and uncoveredVillageSituation != ''">uncovered_village_situation = #{uncoveredVillageSituation},</if>
            <if test="totalSituation != null and totalSituation != ''">total_situation = #{totalSituation},</if>
            <if test="villageGasInfo != null and villageGasInfo != ''">village_gas_info = #{villageGasInfo},</if>
            <if test="townsNewUserInfo != null and townsNewUserInfo != ''">towns_new_user_info = #{townsNewUserInfo},</if>
            <if test="townsGasCoal != null and townsGasCoal != ''">towns_gas_coal = #{townsGasCoal},</if>
            <if test="industryUser != null and industryUser != ''">industry_user = #{industryUser},</if>
            <if test="industryCommerceUser != null and industryCommerceUser != ''">industry_commerce_user = #{industryCommerceUser},</if>
            <if test="commerceCoalGas != null and commerceCoalGas != ''">commerce_coal_gas = #{commerceCoalGas},</if>
            <if test="installPrice != null and installPrice != ''">install_price = #{installPrice},</if>
            <if test="baseSales != null and baseSales != ''">base_sales = #{baseSales},</if>
            <if test="useSalesGrowth != null and useSalesGrowth != ''">use_sales_growth = #{useSalesGrowth},</if>
            <if test="signSalesGrowth != null and signSalesGrowth != ''">sign_sales_growth = #{signSalesGrowth},</if>
            <if test="predictSalesGrowth != null and predictSalesGrowth != ''">predict_sales_growth = #{predictSalesGrowth},</if>
            <if test="predictSalesTotal != null and predictSalesTotal != ''">predict_sales_total = #{predictSalesTotal},</if>
            <if test="otherInfo != null and otherInfo != ''">other_info = #{otherInfo},</if>
            <if test="carGasInfo != null and carGasInfo != ''">car_gas_info = #{carGasInfo},</if>
            <if test="gasTrade != null and gasTrade != ''">gas_trade = #{gasTrade},</if>
            <if test="priceSurvey != null and priceSurvey != ''">price_survey = #{priceSurvey},</if>
            <if test="outstandingPaymentNumber != null and outstandingPaymentNumber != ''">outstanding_payment_number = #{outstandingPaymentNumber},</if>
            <if test="newMarketResident != null and newMarketResident != ''">new_market_resident = #{newMarketResident},</if>
            <if test="sysCtime != null">sys_ctime = #{sysCtime},</if>
            <if test="sysUtime != null">sys_utime = #{sysUtime},</if>
            <if test="createBy != null and createBy != ''">create_by = #{createBy},</if>
            <if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
            <if test="isDelete != null">is_delete = #{isDelete},</if>
            <if test="householdNumberSubtotalBefore != null">household_number_subtotal_before = #{householdNumberSubtotalBefore},</if>
            <if test="predictInstallSubtotalBefore != null">predict_install_subtotal_before = #{predictInstallSubtotalBefore},</if>
            <if test="householdNumberSubtotal != null">household_number_subtotal = #{householdNumberSubtotal},</if>
            <if test="predictInstallSubtotal != null">predict_install_subtotal = #{predictInstallSubtotal},</if>
            <if test="householdNumberTotal != null">household_number_total = #{householdNumberTotal},</if>
            <if test="predictInstallTotal != null">predict_install_total = #{predictInstallTotal},</if>
            <if test="currentInstallSubtotal != null">current_install_subtotal = #{currentInstallSubtotal},</if>
            <if test="afterInstallSubtotal != null">after_install_subtotal = #{afterInstallSubtotal},</if>
            <if test="lastInstallSubtotal != null">last_install_subtotal = #{lastInstallSubtotal},</if>
            <if test="installTotal != null">install_total = #{installTotal},</if>
        </trim>
        where report_no = #{reportNo}
    </update>

    <update id="deleteBusinessAnalyzeById" parameterType="com.chinagas.modules.insight.domian.BusinessAnalyze">
        update business_analyze
        <trim prefix="SET" suffixOverrides=",">
            is_delete = 1
        </trim>
        where report_no = #{reportNo}
    </update>

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