yuxc
2023-11-28 88321ac7b2586106950e2baeaeac5102eedebbb0
Source/UBCS/ubcs-service/ubcs-code/src/main/resources/mapper/CodeALlCodeMapper.xml
@@ -6,11 +6,20 @@
    <resultMap id="CodeAllcodeResultMap" type="com.vci.ubcs.code.entity.CodeAllCode">
    </resultMap>
    <select id="selectCodeAllCodePage" resultMap="CodeAllcodeResultMap">
        select * from PL_CODE_ALLCODE
    </select>
    <select id="selectGroupByClassify" resultMap="CodeAllcodeResultMap">
        select codeClassifyOid,
               codeRuleOid,
               serialUnit,
               max(unFillSerial) unFillSerial
        from (select codeClassifyOid,
                     codeRuleOid,
                     serialUnit,
                     to_number(replace(unFillSerial, ${replaceString}, '')) unFillSerial
              from PL_CODE_ALLCODE where codeClassifyOid in (${codeClassifyOid}))
        group by codeClassifyOid, codeRuleOid, serialUnit
    </select>
</mapper>