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

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
francis_gr
Creator
Creator

how to calculate average value?

Hi!

I have employee table with the sales per year (2011 to 2013)

I need that selecting a employee, calculate the average sales per year of all employees with the same job that the selected person .

I tried with Avg (Total ([ventas])) but doesn´t work (show the same wrong value each year)

Thanks

4 Replies
Greg_Williams
Former Employee
Former Employee

Have you tried avg(aggr(sum(sales),year))

swuehl
MVP
MVP

Maybe something like this:

avg({<JobField = p(), EmployeeField = >} [ventas])

in a chart with dimension Year and selecting in EmployeeField.

francis_gr
Creator
Creator
Author

Thanks for your quick reply!!

I`ve tried your expresíon but it shows the same sales values that the person that i have selected, not the average values per year  of all employees with the same job

Regards

francis_gr
Creator
Creator
Author

Hi!

Thanks for your reply!

Show the same sales values per year that have the selected person, so i haven´t the average per year and job of the group to which the employee selected belongs

Regards