Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
Modernize Your QlikView Deployment webinar, Nov. 3rd. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Contributor III
Contributor III

Use of Aggr in expression

Hello All,

I could use some help with this. It is my understanding that by using Aggr, I can summarize data from my data model in any way I like

and pull it into a chart expression. In the attached example, that is what I am trying to do.

If you look at the Test Fact Chart, It is driven by the dimensions and the Loan Month. I want to incorporate the data from Aggr simulation into this chart. The problem is, that the aggr data is summarized by Payment Month. I want a summary of all payments made where the Payment Month is equal to the Loan Month in the chart.

So, The aggr brings back the totals by 3 dimensions:

Dim1,Dim2,Payment month

Test Fact Chart is:

Dim1,Dim2,Loan Month

I believe that I must somehow rename the 'Payment Month' dimension to 'Loan Month' when it is returned from aggr so that the dimensions in the Test Fact Chart will be respected, is that true ? If I can't somehow rename, Is there another way to accomplish what I want to do ?

Thanks for any help.

Tim

1 Solution

Accepted Solutions
Highlighted
Contributor III
Contributor III

=sum(total Aggr(If(LoanMonth=PaymentMonth,Amt,0),Dim1,Dim2,LoanMonth,PaymentMonth))

View solution in original post

2 Replies
Highlighted
Contributor III
Contributor III

=sum(total Aggr(If(LoanMonth=PaymentMonth,Amt,0),Dim1,Dim2,LoanMonth,PaymentMonth))

View solution in original post

Highlighted
Contributor III
Contributor III

That solution is courtesy of Phil Bishop, thanks Phil!