Skip to main content

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
CUSTOMERS ONLY: Now accepting customer applications for the 2023 Luminary Program: SUBMIT NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
mihai_iov
Creator II
Creator II

Variable from Pivot table data

I have a pivot table with the amount of worked days for each employee,calculated as expressions from the employees' activities, per year. I need to calculate an average an worked days per year and use the said average on some other pivot tables. So as a solution I was thinking about making the said average a variable that I can call in other pivot tables.

Now the question is:

Is there a way in which I can reference an expression in a pivot table, when calculating a variable? If not, is there any other solution to my problem?

1 Solution

Accepted Solutions
marcus_sommer
MVP & Luminary
MVP & Luminary

You couldn't put the multiple results of a pivot within a variable and also you couldn't refer from one object to another. You will always need to calculate your needed results within one object.

In your case you might be getting your results with nested aggregations with the aggr-function, maybe something like this:

avg(aggr(count(WorkingDays), Employee, Year))

To get an explanation what is meant, see: AGGR...

- Marcus

View solution in original post

3 Replies
Anil_Babu_Samineni

Could be

Aggr(Avg(TOTAL <day> [Worked Days Expression], year))

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
Anil_Babu_Samineni

Could be

Aggr(Avg(TOTAL <day> [Worked Days Expression], year))

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
marcus_sommer
MVP & Luminary
MVP & Luminary

You couldn't put the multiple results of a pivot within a variable and also you couldn't refer from one object to another. You will always need to calculate your needed results within one object.

In your case you might be getting your results with nested aggregations with the aggr-function, maybe something like this:

avg(aggr(count(WorkingDays), Employee, Year))

To get an explanation what is meant, see: AGGR...

- Marcus