Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
ha1
Contributor II
Contributor II

% Calculation

Hi Everyone,

I have to calculate Approved rated based on 2 fields.

1. ActualDate, 2. Approved date.

Data:

AppIDActualDateApprovedDateStatusCnt
19/10/20219/10/2021Aprvd1
29/10/20219/11/2021Aprvd1
39/10/20219/10/2021Declnd1
69/10/20219/10/2021Declnd1
49/11/20219/11/2021Aprvd1

 

Expected result:

ActualDateRateFormula(Just for understanding)
9/10/202125% (=1/4)….. only 1 application is approved on 10th out of 4 total applications, one application is approved on 11th so I haven't considered for 10th
9/11/2021200%(=2/1)….. 2 applications are approved on 11th over total applications(1), one application is created on 10th but approved on 11th

 

"ActualDate" field is  dimension.

Actual Approval Rate: Sum({<Status = {'Aprvd'}>}cnt)/sum(Cnt)

but in my requirement Approved count need to consider when  ActualDate = ApprovedDate

 

 

1 Solution

Accepted Solutions
sunny_talwar

The best way to handle this would be to create a Canonical Date in your script

View solution in original post

4 Replies
sunny_talwar

The best way to handle this would be to create a Canonical Date in your script

ha1
Contributor II
Contributor II
Author

looks interesting but creating multiple data sets is highly impossible here as data set huge with multiple dimensions, is there any other suggestions.

ha1
Contributor II
Contributor II
Author

Any Suggestions please?

sunny_talwar

Were you able to resolve it or is this still pending?