Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Count if using set analysis

Hi there Experts,

Hope someone could help me out.

I have a straight table with the following dimensions:

Dimension: Case

Measurements: Set Analysis

PSR Pickup Request Date:

Max({<PSR_or_RMA_Transaction={'PSR'}>}[CreatedDate.autoCalendar.Date])

RMA Online Booking Date:

Max({<PSR_or_RMA_Transaction={'RMA'}>}[CreatedDate.autoCalendar.Date])

# of days aging:

Max({<PSR_or_RMA_Transaction={'RMA'}>}[CreatedDate.autoCalendar.Date]) - Max({<PSR_or_RMA_Transaction={'PSR'}>}[CreatedDate.autoCalendar.Date])

Pass/Fail:

if((Max({<PSR_or_RMA_Transaction={'RMA'}>}[CreatedDate.autoCalendar.Date])-Max({<PSR_or_RMA_Transaction={'PSR'}>}[CreatedDate.autoCalendar.Date]))<=1,'Passed','Failed')

Now, using KPI in my chart:

> I want to count "# of days aging" that are "<=1"

> I want to count "# of days aging" that are ">1"

Thank you so much for your inputs!

Regards,

IC

12 Replies
Anonymous
Not applicable
Author

My apology Olivier, rookie problem.

Don't know if I got the correct formula below, I wasn't able to get the figures that I want.

sum(total if(Aggr((max({<PSR_or_RMA_Transaction={'RMA'}>}[CreatedDate.autoCalendar.Date])-max({<PSR_or_RMA_Transaction={'PSR'}>}[CreatedDate.autoCalendar.Date])),[CreatedDate.autoCalendar.Week], CaseNumber)<=1,1,0))

Thank you so much for any help.

ogautier62
Specialist II
Specialist II

I havn't any more datas to test,

what's wrong ?

maybe remove total after sum(

          or write sum(total <Week> 

Anonymous
Not applicable
Author

I removed the Total after sum and it worked!

Thank you so much Olivier!!!