Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Value assigning to a Variable

Hello all,

On selection of a month from master calender, I want it should give me last four month sales value in 4 variable.

Say:

If I selects Jan of 2014:

V1=100 of Jan 2014

V2= 128 of Dec 2013

V3= 500 of Nov 2013

V4= 400 of Oct 2013.

Sample Data is attached.

Regards,

Balraj

4 Replies
anbu1984
Master III
Master III

Check this qvw

Anonymous
Not applicable
Author

Anbu,

It is not working in case of Fiscal year from April to March.......

Could you suggest, why??

Anonymous
Not applicable
Author

Also,

Its not working for Nov 2013 as well.............

stigchel
Partner - Master
Partner - Master

You say you use a month of a master calendar and I assume those months are real dates (unlike your Sample). If not I would advice you to convert them to real dates, because then you can use calculations like AddMonth(...).

Attached a working example using set analysis with $ sign expansion to use the addmonth function.... (see the text boxes)