Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
baihang-report
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
data-spider
baihang-report
Commits
204bab40
Commit
204bab40
authored
Nov 11, 2019
by
郝彦辉
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
逾期和还款查询sql优化,增加xyqb_i_repayment_plan_bak和xyqb_i_loan_a_m_history_bak临时表
parent
404f3b01
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
8 deletions
+8
-8
LoanApplicationManifestHistoryTask.java
...tgroup/report/job/LoanApplicationManifestHistoryTask.java
+2
-2
RepaymentLoanInfoMapper.xml
...ntgroup/report/mapper/baihang/RepaymentLoanInfoMapper.xml
+6
-6
No files found.
src/main/java/cn/quantgroup/report/job/LoanApplicationManifestHistoryTask.java
View file @
204bab40
...
...
@@ -102,7 +102,7 @@ public class LoanApplicationManifestHistoryTask {
tmp_sql
=
tmp_sql
.
replace
(
"##ENDTIME##"
,
endTime
);
int
upCount
=
xyqbHistoryJdbcTemplate
.
update
(
tmp_sql
);
log
.
info
(
"同步xyqb_i_loan_application_manifest_history数据结束,startTime: {} , 耗时:{} , updateCount: {} "
,
starTime
,
startwatch
.
stop
().
elapsed
(
TimeUnit
.
MILLISECONDS
),
upCount
);
log
.
info
(
"同步xyqb_i_loan_application_manifest_history数据结束,startTime: {} , 耗时:{} , updateCount: {} "
,
starTime
,
startwatch
.
stop
().
elapsed
(
TimeUnit
.
MILLISECONDS
)
+
".ms"
,
upCount
);
}
catch
(
Exception
e
){
log
.
error
(
"同步xyqb_i_loan_application_manifest_history数据异常, startTime: {} , endTime: {} , counter: {} "
,
starTime
,
endTime
,
counter
,
e
);
...
...
@@ -133,7 +133,7 @@ public class LoanApplicationManifestHistoryTask {
tmp_sql
=
tmp_sql
.
replace
(
"##ENDTIME##"
,
endTime
);
int
upCount
=
xyqbHistoryJdbcTemplate
.
update
(
tmp_sql
);
log
.
info
(
"同步xyqb_i_repayment_plan数据结束,startTime: {} , 耗时:{} , updateCount: {} "
,
starTime
,
startwatch
.
stop
().
elapsed
(
TimeUnit
.
MILLISECONDS
),
upCount
);
log
.
info
(
"同步xyqb_i_repayment_plan数据结束,startTime: {} , 耗时:{} , updateCount: {} "
,
starTime
,
startwatch
.
stop
().
elapsed
(
TimeUnit
.
MILLISECONDS
)
+
".ms"
,
upCount
);
}
catch
(
Exception
e
){
log
.
error
(
"同步xyqb_i_repayment_plan数据异常, startTime: {} , endTime: {} , counter: {} "
,
starTime
,
endTime
,
counter
,
e
);
...
...
src/main/resources/cn/quantgroup/report/mapper/baihang/RepaymentLoanInfoMapper.xml
View file @
204bab40
...
...
@@ -334,7 +334,7 @@
<!--3.1百行助贷-非联合贷 实时还款 2019.10.28-->
<select
id=
"findRealTimeRepayMentInfo"
parameterType=
"cn.quantgroup.report.domain.baihang.BaiHangTimeRecord"
resultType=
"cn.quantgroup.report.domain.baihang.RepaymentInfoZhuDai"
>
/*
select
<!--
select
a.id reqID
,'A' opCode
,DATE_FORMAT(now(),'%Y-%m-%dT%H:%i:%S') uploadTs
...
...
@@ -360,7 +360,7 @@
end as loanStatus
,if(f.yqze>0,'overdue','normal') termStatus
from (
select
--
a.*,
select
##
a.*,
a.id,a.user_id,a.loan_application_history_id,a.term_no,a.deadline,a.required_repayment,a.repayment_status,a.repaid_at,a.created_at,
if(c.term_no is null,a.term_no,c.term_no) next_term
,if(c.deadline is null,a.deadline,c.deadline) next_deadline
...
...
@@ -430,7 +430,7 @@
and if(DATEDIFF(a.next_deadline,a.repaid_at)>1,a.term_no,h.max_term)=j.term_no
group by if(d.order_no is null,a.loan_application_history_id,d.order_no),
if(DATEDIFF(a.next_deadline,a.repaid_at)>1,a.term_no,h.max_term);
*/
-->
select
a.id reqID
...
...
@@ -547,7 +547,7 @@
<!--4.1百行助贷-非联合贷 实时逾期还款 2019.10.28-->
<select
id=
"findRealTimeRepayMentOverdue"
parameterType=
"cn.quantgroup.report.domain.baihang.BaiHangTimeRecord"
resultType=
"cn.quantgroup.report.domain.baihang.RepaymentInfoZhuDai"
>
/*
<!--
select
a.id reqID
,'A' opCode
...
...
@@ -573,7 +573,7 @@
end as loanStatus
,'overdue' termStatus
from (
select
--
a.*
select
##
a.*
a.id,a.user_id,a.loan_application_history_id,a.term_no,a.deadline,a.required_repayment,a.repayment_status,a.repaid_at,a.repayment_received_at
from xyqb_i_repayment_plan a
left join xyqb_i_loan_application_manifest_history b
...
...
@@ -600,7 +600,7 @@
where b.funding_corp_id in (420,520,580,650,670,810,240,640,700)
group by a.loan_application_history_id) f on a.loan_application_history_id=f.loan_application_history_id
left join xyqb_i_repayment_record g on a.id=g.repayment_plan_id;
*/
-->
select
a.id reqID
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment