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

Announcements
Posting on Qlik Community is temporarily paused for some users. Thank you for patience and we'll update you soon!
cancel
Showing results for 
Search instead for 
Did you mean: 
RK121
Contributor III
Contributor III

Set Analysis (AVG Aggr)

Hello community,

Calculate YTD - Average:

I am trying to apply set analysis on the table to calculate the Average Count for different types of tickets by Users for the current year.

I also have Couple types of Ticket Action.

I am using this formula, but it doesn't calculate avg for current year per User, per Ticket Action.

=Avg(Aggr(count({$<Year={'=Year(Today())'} >}([Trouble Ticket ID])),[Ticket Action],User))
/
num(Month(now()))

RK121_0-1666107826701.png

 

1 Solution

Accepted Solutions
aschuchner_chicagoatlantic
Contributor II
Contributor II

It looks like you have a problem in your set analysis. It cannot evaluate a formula unless you do it with a $ expansion. Try this:

=Avg(Aggr(count({$<Year={'$(=Year(Today()))'} >}([Trouble Ticket ID])),[Ticket Action],User))

 

View solution in original post

2 Replies
aschuchner_chicagoatlantic
Contributor II
Contributor II

It looks like you have a problem in your set analysis. It cannot evaluate a formula unless you do it with a $ expansion. Try this:

=Avg(Aggr(count({$<Year={'$(=Year(Today()))'} >}([Trouble Ticket ID])),[Ticket Action],User))

 

RK121
Contributor III
Contributor III
Author

Works!Thank you!