diff --git a/src/main/resources/mybatis/mapper/crdn/crndRegistAndView/main/CrdnLevyPrvntcMapper_maria.xml b/src/main/resources/mybatis/mapper/crdn/crndRegistAndView/main/CrdnLevyPrvntcMapper_maria.xml index fe570e4..b6d1b58 100644 --- a/src/main/resources/mybatis/mapper/crdn/crndRegistAndView/main/CrdnLevyPrvntcMapper_maria.xml +++ b/src/main/resources/mybatis/mapper/crdn/crndRegistAndView/main/CrdnLevyPrvntcMapper_maria.xml @@ -45,7 +45,7 @@ pi.PSTN_IDX_NO, -- 위치지수 NO pi.PSTN_IDX, -- 위치지수 substring(t3.ACT_BGNG_YMD,1,4) as ELPS_YR_RDVLRT_YR, - CASE WHEN (CAST(substring(t3.ACT_BGNG_YMD,1,4) as SIGNED)-CAST(t1.CRDN_YR as SIGNED)) >= strct.RDVLRT_CN_YR_CNT THEN strct.LAST_YR_RDVLRT + CASE WHEN ( CAST(t1.CRDN_YR as SIGNED) - CAST(substring(t3.ACT_BGNG_YMD,1,4) as SIGNED) ) >= strct.RDVLRT_CN_YR_CNT THEN strct.LAST_YR_RDVLRT ELSE 1-( (CAST(t1.CRDN_YR as SIGNED) - CAST(substring(t3.ACT_BGNG_YMD,1,4) as SIGNED)) * strct.DPRT