Browse Source

【修复bug】党员学历信息统计总数和总人数不一致

1.数据库中学历字段空字符串和null合并
national_dev
Bill 2 years ago
parent
commit
5dc69dccd1
  1. 6
      code/smart-community/epmet-module/resi-partymember/resi-partymember-server/src/main/resources/mapper/partymember/IcPartyMemberDao.xml

6
code/smart-community/epmet-module/resi-partymember/resi-partymember-server/src/main/resources/mapper/partymember/IcPartyMemberDao.xml

@ -144,11 +144,10 @@
CULTURE AS "code", CULTURE AS "code",
count(ID) AS "value" count(ID) AS "value"
FROM FROM
( SELECT ID, IF(CULTURE = '', NULL, CULTURE) as CULTURE FROM
ic_party_member ic_party_member
WHERE WHERE
DEL_FLAG = '0' DEL_FLAG = '0'
-- AND CULTURE IS NOT NULL
-- AND CULTURE != ''
<choose> <choose>
<when test='orgId != "" and orgId != null'> <when test='orgId != "" and orgId != null'>
AND (SSZB = #{orgId} OR ORG_PIDS LIKE CONCAT('%',#{orgId},'%')) AND (SSZB = #{orgId} OR ORG_PIDS LIKE CONCAT('%',#{orgId},'%'))
@ -157,7 +156,8 @@
AND (AGENCY_ID = #{agencyId} OR AGENCY_PIDS LIKE CONCAT('%',#{agencyId},'%')) AND (AGENCY_ID = #{agencyId} OR AGENCY_PIDS LIKE CONCAT('%',#{agencyId},'%'))
</otherwise> </otherwise>
</choose> </choose>
GROUP BY CULTURE ) ipm
GROUP BY ipm.CULTURE
</select> </select>
<select id="getPartyMemberAgeList" resultType="com.epmet.dto.result.PartyMemberAgeResultDTO"> <select id="getPartyMemberAgeList" resultType="com.epmet.dto.result.PartyMemberAgeResultDTO">
SELECT SELECT

Loading…
Cancel
Save