| | |
| | | (select count(id) from com_mng_population_community_tags where community_id = ${communityId} and label LIKE CONCAT('%','低保户','%')) as lowSecurityTotal , |
| | | (select count(id) from com_mng_population_community_tags where community_id = ${communityId} and label LIKE CONCAT('%','高龄老人','%')) as elderTotal , |
| | | (select count(id) from com_mng_population_community_tags where community_id = ${communityId} and label LIKE CONCAT('%','养老金人员','%')) as pensionTotal, |
| | | (select count(cmpct.id) from com_mng_population_community_tags cmpct left join com_mng_population cmp on cmpct.population_id = cmp.id where cmpct.community_id = ${communityId} and cmp.person_type = 1) AS houseRegTotal, |
| | | (select count(cmpct.id) from com_mng_population_community_tags cmpct left join com_mng_population cmp on cmpct.population_id = cmp.id where cmpct.community_id = ${communityId} and cmp.person_type = 2) AS leftTotal, |
| | | (select count(cmpct.id) from com_mng_population_community_tags cmpct left join com_mng_population cmp on cmpct.population_id = cmp.id where cmpct.community_id = ${communityId} and cmp.person_type = 3) AS outOfTownTotal, |
| | | (select count(cmpct.id) from com_mng_population_community_tags cmpct left join com_mng_population cmp on cmpct.population_id = cmp.id where cmpct.community_id = ${communityId} and cmp.person_type = 4) AS overseasTotal, |
| | | (select count(cmpct.id) from com_mng_population_community_tags cmpct left join com_mng_population cmp on cmpct.population_id = cmp.id where cmpct.community_id = ${communityId} and cmp.person_type = 5) AS floatingTotal, |
| | | (select count(cmpct.id) from com_mng_population_community_tags cmpct left join com_mng_population cmp on cmpct.population_id = cmp.id where cmpct.community_id = ${communityId} and cmp.person_type = 6) AS permanentTotal, |
| | | (select count(cmpct.id) from com_mng_population_community_tags cmpct left join com_mng_population cmp on cmpct.population_id = cmp.id where cmpct.community_id = ${communityId} and cmp.person_type = 7) AS temporaryTotal |
| | | (select count(cmpct.id) from com_mng_population_community_tags cmpct INNER JOIN com_mng_population cmp on cmpct.population_id = cmp.id where cmpct.community_id = ${communityId} and cmp.person_type = 1) AS houseRegTotal, |
| | | (select count(cmpct.id) from com_mng_population_community_tags cmpct INNER JOIN com_mng_population cmp on cmpct.population_id = cmp.id where cmpct.community_id = ${communityId} and cmp.person_type = 2) AS leftTotal, |
| | | (select count(cmpct.id) from com_mng_population_community_tags cmpct INNER JOIN com_mng_population cmp on cmpct.population_id = cmp.id where cmpct.community_id = ${communityId} and cmp.person_type = 3) AS outOfTownTotal, |
| | | (select count(cmpct.id) from com_mng_population_community_tags cmpct INNER JOIN com_mng_population cmp on cmpct.population_id = cmp.id where cmpct.community_id = ${communityId} and cmp.person_type = 4) AS overseasTotal, |
| | | (select count(cmpct.id) from com_mng_population_community_tags cmpct INNER JOIN com_mng_population cmp on cmpct.population_id = cmp.id where cmpct.community_id = ${communityId} and cmp.person_type = 5) AS floatingTotal, |
| | | (select count(cmpct.id) from com_mng_population_community_tags cmpct INNER JOIN com_mng_population cmp on cmpct.population_id = cmp.id where cmpct.community_id = ${communityId} and cmp.person_type = 6) AS permanentTotal, |
| | | (select count(cmpct.id) from com_mng_population_community_tags cmpct INNER JOIN com_mng_population cmp on cmpct.population_id = cmp.id where cmpct.community_id = ${communityId} and cmp.person_type = 7) AS temporaryTotal |
| | | from com_mng_population_community_tags as cmpct inner join com_mng_population as cmp on cmp.id = cmpct.population_id where community_id = ${communityId} |
| | | </select> |
| | | </mapper> |