Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed query for BPA PI search #1102

Merged
merged 1 commit into from
May 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public class EscalationQueryBuilder {

private static final String BASE_QUERY_BPA = "select businessId from (" +
" SELECT *,RANK () OVER (PARTITION BY businessId ORDER BY createdtime DESC) rank_number " +
" FROM eg_wf_processinstance_v2 WHERE businessservice = ? AND tenantid= ? AND action in ('PAY','POST_PAYMENT_APPLY') wf WHERE rank_number = 1 ";
" FROM eg_wf_processinstance_v2 WHERE businessservice = ? AND tenantid= ? AND action in ('PAY','POST_PAYMENT_APPLY') ) wf WHERE rank_number = 1 ";

private static final String QUERY_BPA = "select businessId from eg_wf_processinstance_v2 where businessid in ( ";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,9 @@ public WorkflowQueryBuilder(WorkflowConfig config) {
private static final String STATUS_COUNT_WRAPPER = "select count(DISTINCT wf_id),cq.applicationStatus,cq.businessservice,cq.PI_STATUS as statusId from ({INTERNAL_QUERY}) as cq GROUP BY cq.applicationStatus,cq.businessservice,cq.PI_STATUS";


private static final String BASE_QUERY_BPA = "select businessId from (" +
private static final String BASE_QUERY_BPA = "select id from (" +
" SELECT *,RANK () OVER (PARTITION BY businessId ORDER BY createdtime DESC) rank_number " +
" FROM eg_wf_processinstance_v2 WHERE businessservice = ? AND tenantid= ? AND action in ('PAY','POST_PAYMENT_APPLY') wf WHERE rank_number = 1 ";
" FROM eg_wf_processinstance_v2 WHERE businessservice = ? AND tenantid= ? AND action in ('PAY','POST_PAYMENT_APPLY')) wf WHERE rank_number = 1 ";


private final String paginationWrapper = "SELECT * FROM "
Expand Down