From 119cca45476830b6901c12417e9e9afd742161ae Mon Sep 17 00:00:00 2001 From: jjh Date: Mon, 27 May 2024 09:36:34 +0900 Subject: [PATCH] =?UTF-8?q?=EB=82=A9=EB=B6=80=EC=9E=90=20=ED=85=8C?= =?UTF-8?q?=EC=9D=B4=EB=B8=94=20=EB=B3=80=EA=B2=BD=EC=9C=BC=EB=A1=9C=20?= =?UTF-8?q?=EC=9D=B8=ED=95=9C=20=EC=BF=BC=EB=A6=AC=20=EC=88=98=EC=A0=95.?= =?UTF-8?q?=20=20=20-=20=EB=82=A9=EB=B6=80=EC=9E=90(TB=5FPAYER),=20?= =?UTF-8?q?=EB=82=A9=EB=B6=80=EC=9E=90=20=EC=A3=BC=EC=86=8C(TB=5FPAYER=5FA?= =?UTF-8?q?DDR)=20=ED=85=8C=EC=9D=B4=EB=B8=94=EB=A1=9C=20=EB=B3=80?= =?UTF-8?q?=EA=B2=BD.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mapper/fims/cvlc/crdnCvlcpt-mapper.xml | 2 +- .../sql/mapper/fims/excl/crdnReReg-mapper.xml | 17 +++--- .../sql/mapper/fims/excl/levyExcl-mapper.xml | 7 ++- .../sql/mapper/fims/excl/opnnSbmsn-mapper.xml | 30 +++++----- .../sql/mapper/fims/levy/levy-mapper.xml | 28 +++++----- .../sql/mapper/fims/levy/rduct-mapper.xml | 17 +++--- .../sql/mapper/fims/nxrp/nisA01-mapper.xml | 45 +++++++-------- .../sql/mapper/fims/rcvm/rcvmt-mapper.xml | 24 ++++---- .../sql/mapper/fims/sndb/sndng-mapper.xml | 56 ++++++++++--------- .../sql/mapper/fims/sndb/sndngDtl-mapper.xml | 17 +++--- .../fims/sprt/integrationSearch-mapper.xml | 2 +- 11 files changed, 129 insertions(+), 116 deletions(-) diff --git a/src/main/resources/sql/mapper/fims/cvlc/crdnCvlcpt-mapper.xml b/src/main/resources/sql/mapper/fims/cvlc/crdnCvlcpt-mapper.xml index ccbf4751..42915221 100644 --- a/src/main/resources/sql/mapper/fims/cvlc/crdnCvlcpt-mapper.xml +++ b/src/main/resources/sql/mapper/fims/cvlc/crdnCvlcpt-mapper.xml @@ -354,7 +354,7 @@ SELECT C.CRDN_ID INNER JOIN TB_CRDN_ADI CA ON (C.CRDN_ID = CA.CRDN_ID) INNER JOIN TB_CRDN_CVLCPT CC ON (C.CVLCPT_LINK_YN = 'Y' AND C.LINK_ID = CC.CVLCPT_LINK_ID) LEFT OUTER JOIN TB_PAYER P ON (C.RTPYR_ID = P.RTPYR_ID) - LEFT OUTER JOIN TB_PAYER_ADDR PA ON (P.RTPYR_ID = PA.RTPYR_ID) + LEFT OUTER JOIN TB_PAYER_ADDR PA ON (C.RTPYR_ID = PA.RTPYR_ID AND C.ADDR_SN = PA.ADDR_SN) WHERE C.DEL_YN = 'N' AND C.CRDN_ID = #{crdnId} diff --git a/src/main/resources/sql/mapper/fims/excl/crdnReReg-mapper.xml b/src/main/resources/sql/mapper/fims/excl/crdnReReg-mapper.xml index 2f97d1fd..e0e488b1 100644 --- a/src/main/resources/sql/mapper/fims/excl/crdnReReg-mapper.xml +++ b/src/main/resources/sql/mapper/fims/excl/crdnReReg-mapper.xml @@ -63,14 +63,15 @@ , (SELECT GET_CODE_NM('FIM011', P.RTPYR_SE_CD) FROM DUAL) AS RTPYR_SE_NM , P.RTPYR_NO , P.RTPYR_NM - , P.ZIP - , P.ADDR - , P.DTL_ADDR - FROM TB_CRDN_RE_REG CRR - INNER JOIN TB_CRDN C ON (CRR.CRDN_ID = C.CRDN_ID) - INNER JOIN TB_CRDN_ADI CA ON (C.CRDN_ID = CA.CRDN_ID) - INNER JOIN TB_VLTN V ON (C.VLTN_ID = V.VLTN_ID) - LEFT OUTER JOIN TB_PAYER P ON (C.RTPYR_ID = P.RTPYR_ID) + , PA.ZIP + , PA.ADDR + , PA.DTL_ADDR + FROM TB_CRDN_RE_REG CRR + INNER JOIN TB_CRDN C ON (CRR.CRDN_ID = C.CRDN_ID) + INNER JOIN TB_CRDN_ADI CA ON (C.CRDN_ID = CA.CRDN_ID) + INNER JOIN TB_VLTN V ON (C.VLTN_ID = V.VLTN_ID) + LEFT OUTER JOIN TB_PAYER P ON (C.RTPYR_ID = P.RTPYR_ID) + LEFT OUTER JOIN TB_PAYER_ADDR PA ON (C.RTPYR_ID = PA.RTPYR_ID AND C.ADDR_SN = PA.ADDR_SN) /* 의견제출 대장 목록 조회(opnnSbmsnMapper.selectOpnnSbmsnList) */ @@ -289,12 +290,13 @@ , P.RTPYR_MBL_TELNO , P.RTPYR_EML , P.RTPYR_BRDT - , P.ZIP - , P.ADDR - , P.DTL_ADDR + , PA.ZIP + , PA.ADDR + , PA.DTL_ADDR FROM TB_CRDN C LEFT OUTER JOIN TB_PAYER P ON (C.RTPYR_ID = P.RTPYR_ID) - LEFT OUTER JOIN TB_OPNN_SBMSN OS ON (C.CRDN_ID = OS.CRDN_ID AND OS.DEL_YN = 'N') + LEFT OUTER JOIN TB_PAYER_ADDR PA ON (C.RTPYR_ID = PA.RTPYR_ID AND C.ADDR_SN = PA.ADDR_SN) + LEFT OUTER JOIN TB_OPNN_SBMSN OS ON (C.CRDN_ID = OS.CRDN_ID AND OS.DEL_YN = 'N') /* 부과 대장 목록 조회(levyMapper.selectLevyList) */ diff --git a/src/main/resources/sql/mapper/fims/levy/rduct-mapper.xml b/src/main/resources/sql/mapper/fims/levy/rduct-mapper.xml index 4dbf4c52..24b7aa5c 100644 --- a/src/main/resources/sql/mapper/fims/levy/rduct-mapper.xml +++ b/src/main/resources/sql/mapper/fims/levy/rduct-mapper.xml @@ -68,9 +68,9 @@ , (SELECT GET_CODE_NM('FIM011', P.RTPYR_SE_CD) FROM DUAL) AS RTPYR_SE_NM , P.RTPYR_NO , P.RTPYR_NM - , P.ZIP - , P.ADDR - , P.DTL_ADDR + , PA.ZIP + , PA.ADDR + , PA.DTL_ADDR , (SELECT GET_BRDT_FORMAT(P.RTPYR_BRDT, '.') FROM DUAL) AS RTPYR_BRDT_MASK , L.LEVY_ID , L.LEVY_PCPTAX @@ -84,11 +84,12 @@ , L.LEVY_PCPTAX + L.LEVY_ADAMT AS LEVY_AMT , L.RCVMT_PCPTAX + L.RCVMT_ADAMT AS RCVMT_AMT , L.RDCAMT_PCPTAX + L.RDCAMT_ADAMT AS RDCAMT_AMT - FROM TB_RDUCT R - INNER JOIN TB_CRDN C ON (R.CRDN_ID = C.CRDN_ID) - INNER JOIN TB_CRDN_ADI CA ON (C.CRDN_ID = CA.CRDN_ID) - LEFT OUTER JOIN TB_PAYER P ON (C.RTPYR_ID = P.RTPYR_ID) - LEFT OUTER JOIN TB_LEVY L ON (C.CRDN_ID = L.CRDN_ID AND L.DEL_YN = 'N') + FROM TB_RDUCT R + INNER JOIN TB_CRDN C ON (R.CRDN_ID = C.CRDN_ID) + INNER JOIN TB_CRDN_ADI CA ON (C.CRDN_ID = CA.CRDN_ID) + LEFT OUTER JOIN TB_PAYER P ON (C.RTPYR_ID = P.RTPYR_ID) + LEFT OUTER JOIN TB_PAYER_ADDR PA ON (C.RTPYR_ID = PA.RTPYR_ID AND C.ADDR_SN = PA.ADDR_SN) + LEFT OUTER JOIN TB_LEVY L ON (C.CRDN_ID = L.CRDN_ID AND L.DEL_YN = 'N') diff --git a/src/main/resources/sql/mapper/fims/rcvm/rcvmt-mapper.xml b/src/main/resources/sql/mapper/fims/rcvm/rcvmt-mapper.xml index b7deff8b..39fce3ad 100644 --- a/src/main/resources/sql/mapper/fims/rcvm/rcvmt-mapper.xml +++ b/src/main/resources/sql/mapper/fims/rcvm/rcvmt-mapper.xml @@ -116,22 +116,22 @@ , C.CRDN_PLC , C.CRDN_STTS_CD , C.CRDN_STTS_CHG_DT - , (CONCAT(C.CRDN_YMD, C.CRDN_TM)) AS CRDN_YMD_TM - , (SELECT GET_CODE_NM('FIM010', C.CRDN_STTS_CD) FROM DUAL) AS CRDN_STTS_NM + , (CONCAT(C.CRDN_YMD, C.CRDN_TM)) AS CRDN_YMD_TM + , (SELECT GET_CODE_NM('FIM010', C.CRDN_STTS_CD) FROM DUAL) AS CRDN_STTS_NM , P.RTPYR_ID , P.RTPYR_SE_CD + , (SELECT GET_CODE_NM('FIM011', P.RTPYR_SE_CD) FROM DUAL) AS RTPYR_SE_NM , P.RTPYR_NO , P.RTPYR_NM - , P.RTPYR_BRDT - , P.ZIP - , P.ADDR - , P.DTL_ADDR - , (SELECT GET_CODE_NM('FIM011', P.RTPYR_SE_CD) FROM DUAL) AS RTPYR_SE_NM - , (GET_BRDT_FORMAT(P.RTPYR_BRDT, '.')) AS RTPYR_BRDT_MASK - FROM TB_RCVMT R - LEFT OUTER JOIN TB_LEVY L ON (R.LEVY_ID = L.LEVY_ID) - LEFT OUTER JOIN TB_CRDN C ON (L.CRDN_ID = C.CRDN_ID) - LEFT OUTER JOIN TB_PAYER P ON (C.RTPYR_ID = P.RTPYR_ID) + , (SELECT GET_BRDT_FORMAT(P.RTPYR_BRDT, '.') FROM DUAL) AS RTPYR_BRDT_MASK + , PA.ZIP + , PA.ADDR + , PA.DTL_ADDR + FROM TB_RCVMT R + LEFT OUTER JOIN TB_LEVY L ON (R.LEVY_ID = L.LEVY_ID) + LEFT OUTER JOIN TB_CRDN C ON (L.CRDN_ID = C.CRDN_ID) + LEFT OUTER JOIN TB_PAYER P ON (C.RTPYR_ID = P.RTPYR_ID) + LEFT OUTER JOIN TB_PAYER_ADDR PA ON (C.RTPYR_ID = PA.RTPYR_ID AND C.ADDR_SN = PA.ADDR_SN) /* 단속, 납부자, 부과 대장 객체 가져오기(sndngMapper.selectCrdnPayerTrgts) */ diff --git a/src/main/resources/sql/mapper/fims/sndb/sndngDtl-mapper.xml b/src/main/resources/sql/mapper/fims/sndb/sndngDtl-mapper.xml index 980d2d38..d1945f14 100644 --- a/src/main/resources/sql/mapper/fims/sndb/sndngDtl-mapper.xml +++ b/src/main/resources/sql/mapper/fims/sndb/sndngDtl-mapper.xml @@ -765,9 +765,9 @@ , P.RTPYR_SE_CD , P.RTPYR_NO , P.RTPYR_NM - , P.ZIP - , P.ADDR - , P.DTL_ADDR + , PA.ZIP + , PA.ADDR + , PA.DTL_ADDR , (SELECT GET_CODE_NM('FIM011', P.RTPYR_SE_CD) FROM DUAL) AS RTPYR_SE_NM @@ -775,11 +775,12 @@ - FROM TB_SNDNG_DTL SD - INNER JOIN TB_CRDN C ON (SD.CRDN_ID = C.CRDN_ID) - LEFT OUTER JOIN TB_PAYER P ON (C.RTPYR_ID = P.RTPYR_ID) - LEFT OUTER JOIN TB_SNDNG S ON (SD.SNDNG_ID = S.SNDNG_ID) - LEFT OUTER JOIN TB_EPOST_DLVR_RSLT EDR ON (SD.CON_KEY = EDR.CON_KEY AND SD.RG_NO = EDR.REGINO) + FROM TB_SNDNG_DTL SD + INNER JOIN TB_CRDN C ON (SD.CRDN_ID = C.CRDN_ID) + LEFT OUTER JOIN TB_PAYER P ON (C.RTPYR_ID = P.RTPYR_ID) + LEFT OUTER JOIN TB_PAYER_ADDR PA ON (C.RTPYR_ID = PA.RTPYR_ID AND C.ADDR_SN = PA.ADDR_SN) + LEFT OUTER JOIN TB_SNDNG S ON (SD.SNDNG_ID = S.SNDNG_ID) + LEFT OUTER JOIN TB_EPOST_DLVR_RSLT EDR ON (SD.CON_KEY = EDR.CON_KEY AND SD.RG_NO = EDR.REGINO) WHERE C.SGG_CD = #{sggCd} AND C.TASK_SE_CD = #{taskSeCd} AND (SD.SVBTC_ID IS NULL OR SD.SVBTC_ID = '') diff --git a/src/main/resources/sql/mapper/fims/sprt/integrationSearch-mapper.xml b/src/main/resources/sql/mapper/fims/sprt/integrationSearch-mapper.xml index 32e59a1c..42938c35 100644 --- a/src/main/resources/sql/mapper/fims/sprt/integrationSearch-mapper.xml +++ b/src/main/resources/sql/mapper/fims/sprt/integrationSearch-mapper.xml @@ -161,7 +161,7 @@ LEFT OUTER JOIN TB_LEVY_EXCL LE ON (C.CRDN_ID = LE.CRDN_ID AND LE.DEL_YN = LEFT OUTER JOIN TB_ESB_INTERFACE EI ON (C.LINK_TBL_NM = 'TB_ESB_INTERFACE' AND C.LINK_ID = EI.INTERFACE_SEQ_N) /* 국민신문고 민원 연계 */ LEFT OUTER JOIN TB_SA_CVLCPT_DTL SCD ON (C.LINK_TBL_NM = 'TB_SA_CVLCPT_DTL' AND C.LINK_ID = SCD.DTL_ID) /* 새올 민원 연계 */ LEFT OUTER JOIN TB_PAYER P ON (C.RTPYR_ID = P.RTPYR_ID) /* 납부자 대장 */ -LEFT OUTER JOIN TB_PAYER_ADDR PA ON (P.RTPYR_ID = PA.RTPYR_ID) +LEFT OUTER JOIN TB_PAYER_ADDR PA ON (C.RTPYR_ID = PA.RTPYR_ID AND C.ADDR_SN = PA.ADDR_SN) /* 납부자 주소 대장 */ LEFT OUTER JOIN TB_LEVY L ON (C.CRDN_ID = L.CRDN_ID AND L.DEL_YN = 'N') /* 부과 대장 */ LEFT OUTER JOIN TB_RCVMT R ON (L.LEVY_ID = R.LEVY_ID AND R.DEL_YN = 'N') /* 수납 대장 */ WHERE C.DEL_YN = 'N'