From c2d5c639dc69eaafdaafcc1b7a5e488b0f8c7631 Mon Sep 17 00:00:00 2001 From: weikai <123456> Date: Thu, 25 Feb 2021 14:08:58 +0800 Subject: [PATCH] =?UTF-8?q?[=E5=A4=A7=E5=B1=8F=E6=95=B0=E6=8D=AE=E9=87=87?= =?UTF-8?q?=E9=9B=86=20-=20=E5=85=9A=E5=BB=BA=E6=83=85=E5=86=B5]=20-=20?= =?UTF-8?q?=E6=8E=A5=E5=8F=A3sql=E4=BF=AE=E6=94=B9=20=E9=AD=8F=E5=87=AF=20?= =?UTF-8?q?2021-02-25?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mapper/screen/ScreenPublicDataDao.xml | 166 +++++++++++------- 1 file changed, 99 insertions(+), 67 deletions(-) diff --git a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/screen/ScreenPublicDataDao.xml b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/screen/ScreenPublicDataDao.xml index 89ff6769..c61919cd 100644 --- a/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/screen/ScreenPublicDataDao.xml +++ b/esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/screen/ScreenPublicDataDao.xml @@ -119,16 +119,16 @@ UNION ALL - select GRID_ID, + select DEPT_ID as GRID_ID, 0 as userTotal, 0 AS partyTotal, count(id) as groupTotal, 0 as issueTotal, 0 as topicTotal, 0 as projectTotal, 0 as companyTotal - from esua_epdc_group.epdc_group + from esua_epdc_party_group.epdc_party_group where DEL_FLAG=0 and STATE=10 - group by GRID_ID + group by DEPT_ID union all @@ -163,7 +163,7 @@ 0 as issueTotal, count(id) as topicTotal, 0 as projectTotal, 0 as companyTotal - from esua_epdc_group.epdc_topic + from esua_epdc_party_group.epdc_party_topic where DEL_FLAG=0 group by GRID_ID @@ -251,16 +251,16 @@ UNION ALL UNION ALL - select GRID_ID, + select DEPT_ID as GRID_ID, 0 as userTotal, 0 AS partyTotal, count(id) as groupTotal, 0 as issueTotal, 0 as topicTotal, 0 as projectTotal, 0 as companyTotal - from esua_epdc_group.epdc_group + from esua_epdc_party_group.epdc_party_group where DEL_FLAG=0 and STATE=10 - group by GRID_ID + group by DEPT_ID union all @@ -295,7 +295,7 @@ UNION ALL 0 as issueTotal, count(id) as topicTotal, 0 as projectTotal, 0 as companyTotal - from esua_epdc_group.epdc_topic + from esua_epdc_party_group.epdc_party_topic where DEL_FLAG=0 group by GRID_ID @@ -385,16 +385,16 @@ union all UNION ALL - select GRID_ID, + select DEPT_ID as GRID_ID, 0 as userTotal, 0 AS partyTotal, count(id) as groupTotal, 0 as issueTotal, 0 as topicTotal, 0 as projectTotal, 0 as companyTotal - from esua_epdc_group.epdc_group + from esua_epdc_party_group.epdc_party_group where DEL_FLAG=0 and STATE=10 - group by GRID_ID + group by DEPT_ID union all @@ -429,7 +429,7 @@ union all 0 as issueTotal, count(id) as topicTotal, 0 as projectTotal, 0 as companyTotal - from esua_epdc_group.epdc_topic + from esua_epdc_party_group.epdc_party_topic where DEL_FLAG=0 group by GRID_ID @@ -521,16 +521,16 @@ union all UNION ALL - select GRID_ID, + select DEPT_ID as GRID_ID, 0 as userTotal, 0 AS partyTotal, count(id) as groupTotal, 0 as issueTotal, 0 as topicTotal, 0 as projectTotal, 0 as companyTotal - from esua_epdc_group.epdc_group + from esua_epdc_party_group.epdc_party_group where DEL_FLAG=0 and STATE=10 - group by GRID_ID + group by DEPT_ID union all @@ -565,7 +565,7 @@ union all 0 as issueTotal, count(id) as topicTotal, 0 as projectTotal, 0 as companyTotal - from esua_epdc_group.epdc_topic + from esua_epdc_party_group.epdc_party_topic where DEL_FLAG=0 group by GRID_ID @@ -602,7 +602,6 @@ union all WHERE t.`del_flag`= 0) and city.type_key='district_party' and city.party_code='shibei' GROUP BY city.id -