select thisTab.id, thisTab.system_no, thisTab.related_bill_no, thisTab.source_system, thisTab.business_sector, thisTab.document_type, thisTab.document_no, thisTab.is_internal_settlement, thisTab.internal_settlement_unit, thisTab.customer_name, thisTab.customer_id, thisTab.project_name, thisTab.business_time, thisTab.receivable_confirm_time, thisTab.receivable_amount, thisTab.status, thisTab.remark, thisTab.create_by, thisTab.create_time, thisTab.update_by, thisTab.update_time, thisTab.deleted from receivable_fee_management AS thisTab select count(0) from receivable_fee_management as thisTab and thisTab.system_no = #{systemNo} and thisTab.related_bill_no = #{relatedBillNo} and thisTab.source_system = #{sourceSystem} and thisTab.business_sector = #{businessSector} and thisTab.document_type = #{documentType} and thisTab.document_no = #{documentNo} and thisTab.is_internal_settlement = #{isInternalSettlement} and thisTab.internal_settlement_unit = #{internalSettlementUnit} and thisTab.customer_name like concat('%', #{customerName}, '%') and thisTab.customer_id = #{customerId} and thisTab.project_name like concat('%', #{projectName}, '%') and thisTab.business_time = #{businessTime} and thisTab.receivable_confirm_time = #{receivableConfirmTime} and thisTab.receivable_amount = #{receivableAmount} and thisTab.status = #{status} and thisTab.deleted = #{deleted} insert into receivable_fee_management system_no, related_bill_no, source_system, business_sector, document_type, document_no, is_internal_settlement, internal_settlement_unit, customer_name, customer_id, project_name, business_time, receivable_confirm_time, receivable_amount, status, remark, create_by, create_time, update_by, update_time, deleted, #{systemNo}, #{relatedBillNo}, #{sourceSystem}, #{businessSector}, #{documentType}, #{documentNo}, #{isInternalSettlement}, #{internalSettlementUnit}, #{customerName}, #{customerId}, #{projectName}, #{businessTime}, #{receivableConfirmTime}, #{receivableAmount}, #{status}, #{remark}, #{createBy}, #{createTime}, #{updateBy}, #{updateTime}, #{deleted}, insert into receivable_fee_management (system_no, related_bill_no, source_system, business_sector, document_type, document_no, is_internal_settlement, internal_settlement_unit, customer_name, customer_id, project_name, business_time, receivable_confirm_time, receivable_amount, status, remark, create_by, create_time, update_by, update_time, deleted) values (#{item.systemNo}, #{item.relatedBillNo}, #{item.sourceSystem}, #{item.businessSector}, #{item.documentType}, #{item.documentNo}, #{item.isInternalSettlement}, #{item.internalSettlementUnit}, #{item.customerName}, #{item.customerId}, #{item.projectName}, #{item.businessTime}, #{item.receivableConfirmTime}, #{item.receivableAmount}, #{item.status}, #{item.remark}, #{item.createBy}, #{item.createTime}, #{item.updateBy}, #{item.updateTime}, #{item.deleted}) update receivable_fee_management system_no = #{systemNo}, related_bill_no = #{relatedBillNo}, source_system = #{sourceSystem}, business_sector = #{businessSector}, document_type = #{documentType}, document_no = #{documentNo}, is_internal_settlement = #{isInternalSettlement}, internal_settlement_unit = #{internalSettlementUnit}, customer_name = #{customerName}, customer_id = #{customerId}, project_name = #{projectName}, business_time = #{businessTime}, receivable_confirm_time = #{receivableConfirmTime}, receivable_amount = #{receivableAmount}, status = #{status}, remark = #{remark}, create_by = #{createBy}, create_time = #{createTime}, update_by = #{updateBy}, update_time = #{updateTime}, deleted = #{deleted}, where id = #{id} update receivable_fee_management system_no = #{item.systemNo}, related_bill_no = #{item.relatedBillNo}, source_system = #{item.sourceSystem}, business_sector = #{item.businessSector}, document_type = #{item.documentType}, document_no = #{item.documentNo}, is_internal_settlement = #{item.isInternalSettlement}, internal_settlement_unit = #{item.internalSettlementUnit}, customer_name = #{item.customerName}, customer_id = #{item.customerId}, project_name = #{item.projectName}, business_time = #{item.businessTime}, receivable_confirm_time = #{item.receivableConfirmTime}, receivable_amount = #{item.receivableAmount}, status = #{item.status}, remark = #{item.remark}, create_by = #{item.createBy}, create_time = #{item.createTime}, update_by = #{item.updateBy}, update_time = #{item.updateTime}, deleted = #{item.deleted}, where id = #{item.id} delete from receivable_fee_management where id = #{id} delete from receivable_fee_management where id in #{id}