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

Announcements
See why IDC MarketScape names Qlik a 2025 Leader! Read more
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Problem with variable in the Sum Expression

Hi, I trying to set several expression which should return the sum of the Amount of the Remaining Invoices (Not yet paid). One for the Current week and the others from the previous weeks. The expression CurrentWeek is like that:

Sum({<CalendarWeek={$(vCurrentWeek)}>} [Remaining Invoices.Amount])

And It works.But when I try to set the sum for the previous weeh (CurrentWeek - 1) it fails

Sum({<CalendarWeek={$(vCurrentWeek-1)}>} [Remaining Invoices.Amount])

What Am I doing wrong ?

Thanks in advance.

1 Solution

Accepted Solutions
jagan
Partner - Champion III
Partner - Champion III

Hi,

Try this

Sum({<CalendarWeek={'$(=(vCurrentWeek-1))'}>} [Remaining Invoices.Amount])

Hope it helps you.

Regards,

Jagan.

View solution in original post

2 Replies
jagan
Partner - Champion III
Partner - Champion III

Hi,

Try this

Sum({<CalendarWeek={'$(=(vCurrentWeek-1))'}>} [Remaining Invoices.Amount])

Hope it helps you.

Regards,

Jagan.

Not applicable
Author

That's right! thanks a lot!