Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Avg(Aggr) not working

Hi,

I have a expression, which works fine:

sum({<[Report Date]={">=$(=Date(Yearstart(Max([Report Date]))))<=$(=Date(Max({<DateFlag = {2}>}[Report Date])))"}>}[New Issuance Fee]) /

sum({<[Report Date]={">=$(=Date(Yearstart(Max([Report Date]))))<=$(=Date(Max({<DateFlag = {2}>}[Report Date])))"}>}[New Issuance Principal])

Now I want to take the avg for a time period.

So I wrote my expression as:

avg(aggr(sum({<[Report Date]={">=$(=Date(Yearstart(Max([Report Date]))))<=$(=Date(Max({<DateFlag = {2}>}[Report Date])))"}>}[New Issuance Fee]) /

sum({<[Report Date]={">=$(=Date(Yearstart(Max([Report Date]))))<=$(=Date(Max({<DateFlag = {2}>}[Report Date])))"}>}[New Issuance Principal]), [MonthName of Year]))

Although it doesn't show any error but my values for first and second expression remain same. Can someone tell me whats wrong with my expression.

I'm using MonthName of Year as my dimension.

Thanks for all the help.

Regards,

Aditya

6 Replies
sunny_talwar

The change you have made would only change a number for a total. Are you expecting a change in the rows of your chart? Actually the question to ask here is, are you doing this in a chart or text box object?

Not applicable
Author

Hi Sunny, I'm doing it in a chart.Save.jpg

sunny_talwar

Would you be able to share a sample with your expected output?

Not applicable
Author

Sure Sunny. I'll attach the sample in a new thread and tag you onto it.

sunny_talwar

Sounds good

Not applicable
Author

Done, sent you the qvw.

Issue with avg(aggr)

Thanks for all the help..