Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Not applicable

Need to show the data for past 12 months

Hello Everyone,

Can any body help into this,

I need to create one chart,

Dimension is month,

Measure is Revenue,

My scenario is if i select 2014 i need to show 12 months data, means currently we are in September, i need to show the data from Sep to past 12 months( till last year oct-2013),

If i select 2013 it show 12 months of 2013 data

How to achieve this, can any body help into this,

Thanks in advance

Tags (3)
5 Replies
Siva_Sankar
Honored Contributor

Re: Need to show the data for past 12 months

ecolomer
Honored Contributor II

Re: Need to show the data for past 12 months

You can use MonthYear function

Not applicable

Re: Need to show the data for past 12 months

Thanks for the sharing,

But for me both actions( current Year selection and PY selection) should happen in to the same chart

any other way to do this, please let me know

Not applicable

Re: Need to show the data for past 12 months

Hi ,

Try Like this .

Expression

=sum({<trn_Date={'>=$(VarPrev12Maxdate)  <=$(VarMaxdate)'}>}  amount)

Variables

VarPrev12Maxdate : date(max(trn_Date),'DD-MM-YYYY')

VarMaxdate : Date(AddMonths(VarMaxdate,-12),'DD-MM-YYYY')

Thanks !!

Not applicable

Re: Need to show the data for past 12 months

Not Working