Skip to main content

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
CUSTOMERS ONLY: Now accepting customer applications for the 2023 Luminary Program: SUBMIT NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
kirankkk
Creator II
Creator II

Chart on the last 12 months

I want to show last 12 months in calculated dimension from current month.

6 Replies
tresesco
MVP
MVP

Put months on dimension and expression using set analysis like:

sum({<Date={'>$(=monthstart(max(Date),-12))'}>}Amount)

its_anandrjs

Hi,

Try this if you have any Month Year Field

=SUM({<[Month Year]= {'>=$(=(Max([Month Year])-12))<=$(=Max([Month Year]) )'}>}Revenue)

Regards

Anand

rubenmarin

Hi, you need to ignore selections on date related fields and limit the values for the last 12 months

Sum({<Year,Quarter,Month,DateField={'>$(=MonthStart(max(DateField),-12))<=$(=max(DateField))'}>} ValueField)

kavita25
Partner - Specialist
Partner - Specialist

Hi,

Using Set Analysis in your expression and dimension can be month or MonthYear field  :

sum({<DATE={'>=$(=MonthStart(Max(DATE),-12))<=$(=MonthEnd(Max(DATE),-1))'}>}amount)

Not applicable

add calculated dimension

if(date(date_column,'D/M/YYYY') > date(ur_date, 'date_format') and  date(date_column,'D/M/YYYY') < date(ur_date, 'date_format'), date_column, null())

date_column is dimension field

ur_Date - u can keep date static or dynamic

its_anandrjs

Another One way is

And in dimension Take MonthYear Field

Expre:-  Sum({<Date ={'>$(=((AddMonths( Max(Date),-11))))<=$(=( Max(Date)) )'}>} Sales)

Regards

Anand