Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
Join this live chat April 6, 10AM EST - QlikView to Qlik Sense REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
paul_ripley
Creator III
Creator III

Subtotal not work on expression with Aggr

Hello

I have an expression which works and brings the correct numbers on a line-by-line basis but the totals do not agree to the lines above.  Why would this be and is there anyway to correct this?

+IF(

SUM(Aggr( sum({$<period = {">=$(vStartPeriod_CY)<=$(vEndPeriod_CY)"},pl={"N01","L03","N02","N03","N04","N06"}>}IS_IFRS_GBP),entity_region,entity_description)) >0,

SUM(Aggr( sum({$<period = {">=$(vStartPeriod_CY)<=$(vEndPeriod_CY)"},pl={"N01","L03","N02","N03","N04","N06"}>}IS_IFRS_GBP),entity_region,entity_description))

,0)

Many thanks

Paul

1 Solution

Accepted Solutions
sunny_talwar

May be this:

=Sum(Aggr(If(Sum({$<period = {">=$(vStartPeriod_CY)<=$(vEndPeriod_CY)"},pl={"N01","L03","N02","N03","N04","N06"}>} IS_IFRS_GBP) > 0,

Sum({$<period = {">=$(vStartPeriod_CY)<=$(vEndPeriod_CY)"},pl={"N01","L03","N02","N03","N04","N06"}>} IS_IFRS_GBP), 0), entity_region, entity_description))

View solution in original post

2 Replies
sunny_talwar

May be this:

=Sum(Aggr(If(Sum({$<period = {">=$(vStartPeriod_CY)<=$(vEndPeriod_CY)"},pl={"N01","L03","N02","N03","N04","N06"}>} IS_IFRS_GBP) > 0,

Sum({$<period = {">=$(vStartPeriod_CY)<=$(vEndPeriod_CY)"},pl={"N01","L03","N02","N03","N04","N06"}>} IS_IFRS_GBP), 0), entity_region, entity_description))

View solution in original post

paul_ripley
Creator III
Creator III
Author

Thanks so much for that, was very helpful

Paul