Commit 5750ff88 by 傅伟强-富德

Update test.txt

1 parent 8ac8cd81
Showing with 1 additions and 37 deletions
......@@ -177,44 +177,8 @@ and rpsi.ASSIGN_BRANCH_CODE in
select
要在代码中写一个机制,连接-更新-完成数据库的一个事物时写一次用户信息,确保一次数据库操作(事务)都有写用户信息。这样触发器才能获取到正确的用户
rpsi.POLICY_NO policyNo,rpsi.service_no servicerNo,po.BRANCH_CODE branchCode,si.EMP_NAME empName,
po.CHANNEL_TYPE AS channelType,bi.BRANCH_NAME branchName,ppi.PREM_DUE_DATE premDate,ctl.DESCRIPTION AS description
from policy po
inner join rn_policy_service_info rpsi on rpsi.policy_no=po.policy_no
inner join policy_product pp on pp.policy_no=po.policy_no and pp.prod_seq='1'
inner join policy_prem_info ppi on ppi.policy_no =po.policy_no
inner join CHANNEL_TYPE_TBL CTL on CTL.CHANNEL_TYPE = PO.CHANNEL_TYPE
inner join staff_info si on si.emp_no = rpsi.service_no
inner join branch_info bi on bi.branch_code = po.branch_code
left join gras_assign_failed_record gfr on gfr.policy_no=rpsi.policy_no and gfr.is_valid='Y'
where
gfr.policy_no is null
and ppi.prem_status='1'
and ppi.prem_source='1'
and(rpsi.assign_rule IN ('01', '02') OR rpsi.assign_rule IS NULL)
and pp.product_code not in('CBAN_TN1','CBAN_UN1','CBAN_VN1')
AND ppi.PREM_DUE_DATE >= "TO_DATE"(#{nowMonth},'yyyy-MM-dd hh24:mi:ss')
AND ppi.PREM_DUE_DATE < "TO_DATE"(#{nextMonth},'yyyy-MM-dd hh24:mi:ss')
<choose>
<when test="channelType != null and channelType != ''">
AND po.channel_type = #{channelType,jdbcType=VARCHAR}
</when>
<otherwise>
AND po.channel_type not in ('06','08','11')
</otherwise>
</choose>
and rpsi.ASSIGN_BRANCH_CODE in
(select bcr.branch_code from branch_code_relation bcr where
bcr.relative_grade>-1 and bcr.relative_branch_code=#{branchCode,jdbcType=VARCHAR})
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!