Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Connect 2026! Turn data into bold moves, April 13 -15: Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
khadeer
Specialist
Specialist

Expression?

Hi Friends,

I have Opening balance for every year, field name is OpeningBalance

and amount value of that every month, Suppose my opening balance is 5000

my amount respective months is Apr= 200, May= -100, Jun=100, Here field name is Amount.

Now if i selected Apr month it will show as 5200( OpeningBalance+Amount)

if i selected May 5100, Previous month value- present month(5200-100)

i am getting cumulative in respective amount field by writing

sum({<Month={$(=max(Month))>}Amount), but i want to show cumilative including that opningbalance.

4 Replies
perumal_41
Partner - Specialist II
Partner - Specialist II

Hi,

Please Upload Sample Application for Reference

Not applicable

Have you tried the following expression, omitting the month selection for OpeningBalance?

sum({<Month={$(=max(Month))>}Amount) + sum({<Month=>}OpeningBalance)

JG

khadeer
Specialist
Specialist
Author

I tried that but its not working.

My problem is i am getting correct value for individual months, when i am taking 2 r more months suppose Apr+May, its taking addition of both, but i want may only, if selected Q1 ... it has to show june end value.... if my selection is Q+Q2 ... i want to show sept value only

perumal_41
Partner - Specialist II
Partner - Specialist II

Hi,

Try this one

Rangesum({<Month={$(=max(Month))>}Amount) + sum({<Month=>}OpeningBalance).if is not working this expression .please upload sample Appliation