`id`,`user_id`,`tenant_id`,`parent_tenant_id`,`open_id`,`union_id`,`nick_name`,`gender`,`avatar_url`,`phone`,`pure_phone`, `city`,`province`,`language`,`country_code`,`register_ip`,`verify_code_phone`, `qrcode_source`,`scene`,`scene_address`,`session_key`,`score`, `update_date`,`create_date`,`app_id`,`token`,`expire_time`,`latitude`, `longitude`, `login_count`, `extra_info`, `is_subscribe`, `open_app_id`, `mp_open_id`,`mp_app_id`,`mp_subscribe`,`mp_subscribe_time`,`mp_subscribe_scene`, `subs_open_id`,`subs_app_id`,`subs_subscribe`,`subs_subscribe_time`,`subs_subscribe_scene`,`credit`,`active_time` where 1 = 1 and `id` = #{id} and `user_id` = #{userId} and `tenant_id` = #{tenantId} and `parent_tenant_id` = #{parentTenantId} and `open_id` = #{openId} and `union_id` = #{unionId} and `nick_name` like concat('%', #{nickName},'%') and `gender` = #{gender} and `avatar_url` like concat('%', #{avatarUrl},'%') and `phone` like concat('%', #{phone},'%') and `pure_phone` like concat('%', #{purePhone},'%') and `city` like concat('%', #{city},'%') and `province` like concat('%', #{province},'%') and `language` like concat('%', #{language},'%') and `country_code` like concat('%', #{countryCode},'%') and `register_ip` like concat('%', #{registerIp},'%') and `verify_code_phone` like concat('%', #{verifyCodePhone},'%') and `qrcode_source` like concat('%', #{qrcodeSource},'%') and `scene` like concat('%', #{scene},'%') and `scene_address` like concat('%', #{sceneAddress},'%') and `session_key` like concat('%', #{sessionKey},'%') and `score` = #{score} and `update_date` = #{updateDate} and `create_date` = #{createDate} and `app_id` like concat('%', #{appId},'%') and `token` like concat('%', #{token},'%') and `expire_time` = #{expireTime} and `latitude` = #{latitude} and `longitude` = #{longitude} and `login_count` = #{loginCount} and `extra_info` = #{extraInfo} and `is_subscribe` = #{isSubscribe} and `open_app_id` = #{openAppId} and `mp_open_id` = #{mpOpenId} and `mp_app_id` = #{mpAppId} and `subs_open_id` = #{subsOpenId} and `subs_app_id` = #{subsAppId} and `credit` = #{credit} and id in #{idItem} order by ${sortColumns} update wx_c_user set msg_count = msg_count+1 where 1=1 and `id` = #{id} and `open_id` = #{openId} and `tenant_id` = #{tenantId} and `parent_tenant_id` = #{parentTenantId} update wx_c_user set msg_count = msg_count-1 where msg_count > 0 and `tenant_id` = #{tenantId} and `parent_tenant_id` = #{parentTenantId} and `open_id` in #{openId} update wx_c_user set user_id=#{userId} where id = #{id} update wx_c_user set update_date=now(), token = null, expire_time=now(), tenant_id = IF(tenant_id is null ,null,CONCAT(tenant_id,"_del")), parent_tenant_id = IF(parent_tenant_id is null ,null,CONCAT(parent_tenant_id,"_del")), open_id = IF(open_id is null ,null,CONCAT(open_id,"_del")), union_id = IF(union_id is null ,null,CONCAT(union_id,"_del")) where user_id = #{userId} and tenant_id = #{tenantId} and id != #{id}