Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
ljames88
Contributor
Contributor

Adding in set analysis

Here is the issue.

I am trying to figure out how many times during an hour a call was placed by a person.  If 5 calls or less was made in hour 8, then give give a result of 0, if more than 5 then give me a result of 1.  However I need it to be able to add based on different days.

For example.

01/01/2018 at 8 the person made 4 calls

01/02/2018 at 8 the person made 6 calls

01/03/2018 at 8 the person made 9 calls

01/04/2018 at 8 the person made 1 calls

01/05/2018 at 8 the person made 10 calls


For my pivot table I have the following set analysis

(If(Count({<CallTimeHOUR = {6}>} CallTime)< 5,0,1)


When I look at it for the day, it works, however when looking at it for the week it does not.


The result for each day would be

01/01/2018 - 0

01/02/2018 - 1

01/03/2018 - 1

01/04/2018  - 0

01/05/2018  - 1


But when I group the pivot table by the week, I would just get the result of 1, but I am looking for the result of 3.


What am I doing wrong.


Thanks in Advance!!

2 Replies
Anil_Babu_Samineni

Can you please share Sample? May be try this?

(If(Count(TOTAL <Week> {<CallTimeHOUR = {6}>} CallTime)< 5,0,1)


Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
sunny_talwar

Try this

Sum(Aggr(If(Count({<CallTimeHOUR = {6}>} CallTime)< 5,0,1), Date))