Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements
QlikView Fans! We’d love to hear from you.
Share your QlikView feedback with the product team… Click here to participate in our 5-minute survey.
Rules, plus terms and conditions, can be found here.
paulyeo11
Valued Contributor II

How to modify the expression So that it still work when current month and year not selected

Hi All

I have below expression working fine ( Ref to chart 1 ) , when year = 16 and month = 3 :-

sum({$<year = {$(=max(year))}, month = {"<=$(=max({<year={$(=max(year))}>} month))"}>} sales)/1000

May i know how to change the above expression still working , when year and month is not selected. So that i can use the same expression in QS. with out need to activate current month and current year.

Paul

1 Solution

Accepted Solutions

Re: How to modify the expression So that it still work when current month and year not selected

Try this expression:

sum({$<year = {$(=max({<sales = {'*'}>}year))}, month = {"<=$(=max({<year={$(=max({<sales = {'*'}>}year))}>} month))"}>} sales)/1000

2 Replies

Re: How to modify the expression So that it still work when current month and year not selected

Try this expression:

sum({$<year = {$(=max({<sales = {'*'}>}year))}, month = {"<=$(=max({<year={$(=max({<sales = {'*'}>}year))}>} month))"}>} sales)/1000

paulyeo11
Valued Contributor II

Re: How to modify the expression So that it still work when current month and year not selected

Hi sunny

Thank you vey much.

Paul

Community Browser