Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Modernize Your QlikView Deployment webinar, Nov. 3rd. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
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
Highlighted
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
Highlighted

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)
Highlighted

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)
Highlighted
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