huanghongfa
2021-12-09 9576bebcacea938771f6f5b51d958e6a4ac59df6
springcloud_k8s_panzhihuazhihuishequ/service_grid/src/main/resources/mapper/EventMapper.xml
@@ -1352,8 +1352,8 @@
      SELECT
         count( id ) as populationTotal,
         (select count(id) from com_mng_population where village_id = #{villageId} and out_or_local = 1) as localTotal,
         (select count(id) from com_mng_population where village_id = #{villageId} and out_or_local = 2) as localTotal,
         (select count(id) from com_mng_population_community_tags as cmpct left join com_mng_population as cmp on cmpct.population_id = cmp.id where cmp.village_id = #{villageId} and cmpct.label is not null) as specialTotal,
         (select count(id) from com_mng_population where village_id = #{villageId} and out_or_local = 2) as outTotal,
         (select count(cmp.id) from com_mng_population_community_tags as cmpct left join com_mng_population as cmp on cmpct.population_id = cmp.id where cmp.village_id = #{villageId} and cmpct.label is not null) as specialTotal,
         (select count(id) from com_mng_building where village_id = #{villageId}) as buildTotal
      FROM
         com_mng_population AS cmp