zoukankan      html  css  js  c++  java
  • update语句

        <update id="updateOrgEntity">
            UPDATE t_base_org t
            <trim prefix="set" suffixOverrides=",">
                <if test="orgCode!=null">t.org_code=#{orgCode},</if>
                <if test="orgName!=null">t.org_name=#{orgName},</if>
                <if test="companyCode!=null">t.company_code=#{companyCode},</if>
                <if test="companyName!=null">t.company_name=#{companyName},</if>
                <if test="province!=null">t.province=#{province},</if>
                <if test="city!=null">t.city=#{city},</if>
                <if test="county!=null">t.county=#{county},</if>
                <if test="street!=null">t.street=#{street},</if>
                <if test="provinceName!=null">t.province_name=#{provinceName},</if>
                <if test="cityName!=null">t.city_name=#{cityName},</if>
                <if test="countyName!=null">t.county_name=#{countyName},</if>
                <if test="streetName!=null">t.street_name=#{streetName},</if>
                <if test="orgAddress!=null">t.org_address=#{orgAddress},</if>
                <if test="orgActive!=null">t.org_active=#{orgActive},</if>
                <if test="orgKind!=null">t.org_kind=#{orgKind},</if>
                <if test="orgPerson!=null">t.org_person=#{orgPerson},</if>
                <if test="orgPersonMobile!=null">t.org_person_mobile=#{orgPersonMobile},</if>
                <if test="modifyTime!=null">t.modify_time=#{modifyTime},</if>
                <if test="modifyUserCode!=null">t.modify_user_code=#{modifyUserCode},</if>
                <if test="modifyUserName!=null">t.modify_user_name=#{modifyUserName},</if>
                <if test="orgType!=null">t.org_type=#{orgType},</if>
                <if test="orgPhone!=null">t.org_phone=#{orgPhone},</if>
                <if test="jingwei!=null">t.jingwei=#{jingwei},</if>
                <if test="parentCode!=null">t.parent_code=#{parentCode},</if>
            </trim>
            <choose>
                <when test="id !=null">
                    where id=#{id}
                </when>
                <otherwise>
                    WHERE t.org_code=#{orgCode} AND  t.company_code=#{companyCode}
                </otherwise>
            </choose>
        </update>
    

      

  • 相关阅读:
    throw关键字
    Android WebView 调试方法
    webpack的Hot Module Replacement运行机制
    如何使用Node.js编写命令工具——以vue-cli为例
    webpack3新特性简介
    node.js如何制作命令行工具(一)
    webpack务虚扫盲
    web worker 扫盲篇
    httpd配置ResponseHeader
    针对iPhone的pt、Android的dp、HTML的css像素与dpr、设计尺寸和物理像素的浅分析
  • 原文地址:https://www.cnblogs.com/feifeicui/p/9811062.html
Copyright © 2011-2022 走看看