`user_id`,`account`,`password`,`openid`,`session_key`,`unionid`,`phone`,`nick_name`,`name`,play_pwd,
`community_id`,`sex`,`id_card`,`birthday`,`image_url`,`type`,`job`,`is_volunteer`,`is_partymember`,
`status`,`create_at`,`last_login_time`,`tags`,`family_id`,`face_url`,`face_state`,`reject_reson`,`area_id`,
`card_photo_front`,`card_photo_back`,`family_book`,`continuous_landing_days`,`is_tips`,`work_status`,
`work_start_time`,`work_end_time`,`big_age_tips`,love_integral
UPDATE sys_user u
SET u.continuous_landing_days =
IF
(
DATE_FORMAT( u.last_login_time, '%m-%d-%Y' )= DATE_FORMAT( SYSDATE(), '%m-%d-%Y' ),
u.continuous_landing_days + 1,
0)
select id,create_at,state,name,phone,photo_path,political_face,reject_reson,apply_reson,address,age,job,integral,love_integral
community_id,submit_user_id from com_mng_volunteer_mng where phone=#{phone} order by create_at desc limit 1
SELECT
COUNT(a.id)
FROM
com_pb_member_role a
WHERE
a.phone = #{phone} and community_id = #{userCommunityId}
select
u.user_id,
u.phone,
u.nick_name,
u.name,
u.tags,
a.name communityName,
u.status,
u.create_at,
u.love_integral,
u.play_pwd,
u.last_login_time
from sys_user u
left join com_act a on u.community_id=a.community_id
where
u.type=1 and u.community_id is not null and u.app_id =#{pageUserAppletsBackstageDTO.appId}
and u.phone=#{pageUserAppletsBackstageDTO.phone}
and
u.community_id = #{pageUserAppletsBackstageDTO.communityId}
and
u.status=#{pageUserAppletsBackstageDTO.status}
and u.create_at between
#{pageUserAppletsBackstageDTO.createAtBegin} and #{pageUserAppletsBackstageDTO.createAtEnd}
and u.last_login_time between
#{pageUserAppletsBackstageDTO.lastLoginTimeBegin} and #{pageUserAppletsBackstageDTO.lastLoginTimeEnd}
order by u.create_at desc
SELECT
COUNT(user_id)allUser,
COUNT(case WHEN DATE_FORMAT(t.create_at,'%m-%d-%Y')=DATE_FORMAT(SYSDATE(),'%m-%d-%Y') then user_id else null end )addUser,
COUNT(case WHEN DATE_FORMAT(last_login_time,'%m-%d-%Y')=DATE_FORMAT(SYSDATE(),'%m-%d-%Y') then user_id else null end )activeDayUser,
(SELECT count(user_id) FROM sys_user t left join com_act t1 on t.community_id = t1.community_id WHERE t.type = 1 and t.app_id = #{areaCode} AND last_login_time > date_sub(SYSDATE(), INTERVAL 7 DAY))activeWeekUser
FROM
sys_user t LEFT JOIN com_act t1 on t.community_id = t1.community_id
where t.type=1 and t.community_id is not null and t.app_id = #{areaCode}
SELECT
u.user_id,
u.account,
u.`name`,
u.`password`,
u.phone,
e.role_name,
e.role_id ,
u.`status`,
u.love_integral,
u.create_at,
u.last_login_time
FROM
sys_user u
JOIN sys_user_role r ON u.user_id = r.user_id
JOIN sys_role e ON r.role_id = e.role_id
left join com_act ca on u.community_id = ca.community_id
and
e.role_id=#{administratorsUserVO.roleId}
u.type=3
AND u.community_id =
#{administratorsUserVO.communityId}
AND u.name
like concat (#{administratorsUserVO.name},'%')
AND
u.phone like concat(#{administratorsUserVO.phone},'%')
AND
u.account like concat(#{administratorsUserVO.account},'%')
order by u.create_at desc
SELECT DATE_FORMAT( u.create_at, '%Y-%m-%d' ) as specificDate,count( u.user_id ) total FROM sys_user u
LEFT JOIN com_act t1 ON u.community_id = t1.community_id WHERE u.type = 1 AND u.app_id = #{appId} AND u.create_at > #{createAt} GROUP BY specificDate;
SELECT DATE_FORMAT( u.last_login_time, '%Y-%m-%d' ) as specificDate,count( u.user_id ) total FROM sys_user u
LEFT JOIN com_act t1 ON u.community_id = t1.community_id WHERE u.type = 1 AND u.app_id = #{appId} AND u.last_login_time > #{lastLoginTime} GROUP BY specificDate;
update sys_user set status = #{gridMemberEditDTO.status} where user_id in
#{item}
select su.user_id,su.image_url,su.nick_name,su.account,su.phone,su.work_status,su.`status`,ca.name as
communityName,su.work_start_time,su.work_end_time from sys_user su left join com_act as ca on ca.community_id =
su.community_id where su.type = 6
AND su.status =
#{memberRelationDTO.status}
AND ca.community_id =
#{memberRelationDTO.gridCommunityId}
AND ca.street_id = #{memberRelationDTO.gridStreetId}
AND su.work_status = #{memberRelationDTO.workStatus}
and (su.nick_name
like concat(#{memberRelationDTO.keyWord},'%') OR su.user_id = #{memberRelationDTO.keyWord} OR su.account
like concat(#{memberRelationDTO.keyWord},'%') OR su.phone like concat(#{memberRelationDTO.keyWord},'%'))
order by su.create_at desc
update com_pb_service_team u set u.phone=#{newphone},is_reg=1 where u.phone=#{oldphone}
delete from com_shop_store where delete_status = 1 and phone = #{phone}
select id from com_pb_member where audit_result = 1 and id_card = #{idCard}
select user_id,nick_name,phone from sys_user where type = 6 and community_id = #{communityId} limit 3
update sys_user set card_photo_front = #{userArchivesVO.cardPhotoFront}
, card_photo_back = #{userArchivesVO.cardPhotoBack}
,family_book = #{userArchivesVO.familyBook}
,job = #{userArchivesVO.job}
where user_id = #{userArchivesVO.userId}
SELECT
COUNT(ur.role_id)
FROM
sys_user u LEFT JOIN sys_user_role ur ON u.user_id = ur.user_id
LEFT JOIN sys_role r ON ur.role_id = r.role_id
WHERE ur.role_id IS NOT NULL AND u.phone = #{phone} and r.community_id = #{userCommunityId}
delete from event_grid_member_building_relation where grid_member_id = #{gridMemberId}
update com_shop_store set sys_user_id = #{sysUserId} where phone = #{phone}
update com_pb_member set user_id = #{userId} where audit_result = 1 and id_card = #{idCard}
select id as managerId,`name` from com_pb_service_team where community_id = #{communityId}
AND `name` like concat(#{param},'%')
SELECT
u.user_id,
u.face_url,
u.nick_name,
u.`name`,
u.phone,
u.id_card,
u.face_state,
u.love_integral,
c.area_name communityName,
u.create_at
FROM
sys_user u
JOIN com_mng_struct_area c ON u.area_id = c.id
AND c.`area_name` like concat(#{loginUserInfoVO.communityName},'%')
where u.face_state is not null and u.type=1 and u.community_id = #{loginUserInfoVO.communityId}
and u.`name` like concat(#{loginUserInfoVO.name},'%')
AND u.phone like concat(#{loginUserInfoVO.phone},'%')
order by u.face_state asc,u.create_at asc
update sys_user set tags = #{sysUserDO.tags} where user_id = #{sysUserDO.userId}
update com_pb_member_role u set u.phone=#{newphone},is_reg=1 where u.phone=#{oldphone}
SELECT
COUNT(a.id)
FROM
com_pb_service_team a
WHERE
a.phone = #{phone} and community_id = #{userCommunityId}
SELECT
u.user_id 'order',
h.house_name doorNumber,
if(h.state=2,'租住','自主')isRent,
u.`name`,
'汉' nation,
if(u.is_partymember=1,'党员','群众')politicalOutlook,
'未知' maritalStatus,
u.phone,
'未知' education,
u.id_card,
'未知' company,
'未知' residence,
'未知' isPanZhiHua,
'未知' situation,
'未知' isContact,
'未知' major,
'未知' soldier,
'未知' disability,
'未知' lowIncomeHouseholds,
'未知' lowIncomePeople,
'未知' oldPeople,
'未知' specialServiceFamily,
'未知' keyPersonnel
FROM
sys_user u
left join com_mng_struct_house_user hu on hu.user_id=u.user_id
left join com_mng_struct_house h on hu.house_code=h.house_code
JOIN
com_mng_struct_area c ON u.area_id = c.id
LEFT JOIN
com_mng_struct_area c ON u.area_id = c.id
AND c.`area_name`
like concat(#{exportUserDTO.areaName},'%')
where u.community_id = #{exportUserDTO.communityId} and u.type=1
and u.`name` like
concat(#{exportUserDTO.name},'%')
AND u.phone like
concat(#{exportUserDTO.phone},'%')
group by u.user_id
select * from
sys_user_notice
where
user_id=#{pageDTO.userId}
and type=#{pageDTO.type}
order by create_at desc
SELECT
COUNT(h.id)
FROM
com_mng_struct_area a
LEFT JOIN com_mng_struct_house h on h.parent_code=a.area_code
WHERE
a.area_name = #{areaName}
update sys_user set password = #{gridMemberDTO.password} where user_id in
#{item}
update sys_user set nick_name=null ,community_id=null,area_id=null where user_id=#{userId}
select COUNT(a.id) from com_mng_struct_area a where a.area_name=#{areaName}
update lc_compare_code_member set local_grid_member_id = #{userId},grid_member_name = #{userName} where id = #{lcMemberId}
update sys_user set face_state=null where user_id=#{userId}
delete from lc_compare_code_member where local_grid_member_id = #{gridMemberId}
select id,village_id,act_id from com_mng_building where id = #{buildingId}
select lc_grid_member_id,lc_grid_member_name,lc_bind_user_id from lc_compare_code_member where local_grid_member_id = #{gridMemberId}
select count(id) from event_grid_member_relation where grid_member_id = #{userId}
SELECT
street_id,
`name`,(
SELECT
count( user_id )
FROM
sys_user AS su
LEFT JOIN com_act AS ca ON ca.community_id = su.community_id
WHERE
type = 1 and state = 0 and ca.app_id = #{areaCode}
AND ca.street_id = cs.street_id
) AS userNum
FROM
`com_street` AS cs where cs.app_id = #{areaCode}
order by userNum desc
SELECT COUNT(id) FROM com_property
WHERE user_id = #{userId} AND community_id = #{communityId}
select count(id) from com_act_social_worker where telephone = #{phone} and community_id = #{communityId}
select count(id) from com_act_social_org where user_id = #{userId}
SELECT COUNT(id) FROM com_fms_team_member
WHERE phone = #{phone} AND community_id = #{communityId}
SELECT street_id, area_code FROM com_street WHERE street_id = #{streetId}
SELECT COUNT(id) FROM com_act_social_member
WHERE user_id = #{userId}
SELECT COUNT(id)
FROM com_act_social_org
WHERE contact_phone = #{phone} AND is_society = 1
SELECT COUNT(id)
FROM com_act_dpc
WHERE phone = #{phone} AND community_id = #{userCommunityId} AND is_del = 0
SELECT COUNT(id) FROM com_act_easy_photo_member
WHERE phone = #{phone} AND community_id = #{communityId}
SELECT id, relation_name FROM com_act_acid_member WHERE phone = #{phone}
select t.district_name from com_mng_struct_area_district t left join com_street t1 on t.district_adcode = t1.area_code where t1.street_id =#{streetId}
select count(*) from com_pb_check_unit where admin_phone like concat('%',#{phone},'%')
select id from com_pb_check_unit where admin_phone like concat('%',#{phone},'%')
select check_unit_id from com_pb_member where phone = #{phone} limit 1
select cs.area_code,cs.name as streetName,ac.name as communityName,count(su.user_id) as user,su.community_id as communityId from sys_user as su
left join com_act as ac on su.community_id=ac.community_id
left join com_street as cs on ac.street_id=cs.street_id
where su.community_id<>''
and cs.area_code<>''
and su.create_at >= #{range}
and su.app_id = #{appId}
and ac.area_code=#{areaCode}
group by cs.street_id
and cs.street_id=#{streetId}
and su.community_id<>11
group by su.community_id
group by cs.area_code
group by cs.street_id
and su.community_id<>11
group by su.community_id
order by user desc
limit 10
select cs.area_code as areaCode,cs.street_id,ac.name as communityName,su.community_id as communityId,
cs.name as StreetName,count(su.user_id) as count from sys_user as su
left join com_act as ac on su.community_id=ac.community_id
left join com_street as cs on ac.street_id=cs.street_id
where su.community_id<>''
and cs.area_code<>''
and su.id_card<>''
and su.create_at >= #{range}
and su.app_id = #{appId}
and ac.area_code=#{areaCode}
group by cs.street_id
and cs.street_id=#{streetId}
group by su.community_id
group by cs.area_code
group by cs.street_id
group by su.community_id
order by count desc
limit 11
select count(user_id) from sys_user as su
left join com_act as ac on su.community_id=ac.community_id
left join com_street as cs on ac.street_id=cs.street_id
where su.community_id<>''
and cs.area_code<>''
and cs.street_id=#{id}
and ac.area_code=#{areaCode}
SELECT
COUNT(user_id)allUser,
COUNT(case WHEN DATE_FORMAT(t.create_at,'%m-%d-%Y')=DATE_FORMAT(SYSDATE(),'%m-%d-%Y') then user_id else null end )addUser,
COUNT(case WHEN DATE_FORMAT(last_login_time,'%m-%d-%Y')=DATE_FORMAT(SYSDATE(),'%m-%d-%Y') then user_id else null end )activeDayUser,
(SELECT count(user_id) FROM sys_user t left join com_act t1 on t.community_id = t1.community_id WHERE t.type = 1 AND last_login_time > date_sub(SYSDATE(), INTERVAL 7 DAY))activeWeekUser
FROM
sys_user t LEFT JOIN com_act t1 on t.community_id = t1.community_id
where t.type=1 and t.community_id is not null
and t1.street_id=#{streetId}
and t1.area_code=#{areaCode}
and t.create_at >= #{range}
and t.community_id<>11
select COUNT(case WHEN DATE_FORMAT(su.last_login_time,'%m-%d-%Y')=DATE_FORMAT(#{date},'%m-%d-%Y') then user_id else null end) as activeUser,
count(case WHEN DATE_FORMAT(su.create_at,'%m-%d-%Y')=DATE_FORMAT(#{date},'%m-%d-%Y') then user_id else null end ) as addUser
from sys_user as su
left join com_act as ac on su.community_id=ac.community_id
left join com_street as cs on ac.street_id=cs.street_id
where su.community_id<>''
and cs.area_code<>''
and su.type = 1
and su.app_id = #{appId}
and cs.street_id=#{id}
and cs.area_code=#{areaCode}
SELECT DATE_FORMAT( su.create_at, '%Y-%m-%d' ) as specificDate ,count(su.user_id) as total FROM
sys_user AS su
LEFT JOIN com_act AS ac ON su.community_id = ac.community_id
LEFT JOIN com_street AS cs ON ac.street_id = cs.street_id
where su.community_id<>''
and cs.area_code<>''
and su.type = 1
and su.app_id = #{appId}
and cs.street_id=#{id}
and cs.area_code=#{areaCode}
AND su.create_at > #{createAt} GROUP BY specificDate
SELECT DATE_FORMAT( su.last_login_time, '%Y-%m-%d' ) as specificDate ,count(su.user_id) as total FROM
sys_user AS su
LEFT JOIN com_act AS ac ON su.community_id = ac.community_id
LEFT JOIN com_street AS cs ON ac.street_id = cs.street_id
where su.community_id<>''
and cs.area_code<>''
and su.type = 1
and su.app_id = #{appId}
and cs.street_id=#{id}
and cs.area_code=#{areaCode}
AND su.last_login_time > #{lastLoginTime} GROUP BY specificDate
select street_id as id,name as name from com_street where area_code=#{code} and app_id ='wx118de8a734d269f0'
select street_id as id,name as name from com_street where area_code=#{code}
select * from com_act_acid_check_record where id = #{id}
select * from com_act_acid_record where id = #{id}
select * from com_act_acid_member where id = #{id}
SELECT count(user_id)
FROM
sys_user t LEFT JOIN com_act t1 on t.community_id = t1.community_id
where t.type=1 and t.community_id is not null
and t.community_id<>11
and t1.street_id=#{streetId}
and t1.area_code=#{areaCode}
and t.create_at >= #{range}
and t.app_id = #{appId}
select user_id from sys_user where account in
#{name}
select cs.street_id as id,cs.name as name
from sys_user as su
left join com_street as cs on su.name=cs.name
where su.account=#{name}
limit 1
select * from com_sanshuo_expert where phone=#{phone}
select count(id) from com_sanshuo_industry_center where account=#{account}
select count(id) from com_sanshuo_expert where account=#{account}
select count(id) from com_act_dpc where name =#{name} and phone=#{phone}
select id from com_property where phone=#{phone}