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

10 day rolling chart help

we have to develop a 10 day rolling chart for sales.

when user select a month it should start from the max(date) till past 10 days

when user select a particular date , (ex: 03/25/2013) - it should start from 3/25 till past 10 days ...

My dimension is Date

expression: sum({<Date=">=$(=Max(Date-10)<=$(=Max(Date)))">}Sales)

this is not working ....

do i need to use valueloop to handle this ?

3 Replies
sr_qlikview
Creator
Creator
Author

any idea ?

udit_kumar_sana
Creator II
Creator II

Hi,

You can use the below expressions for this :

sum({$<DATE={"<=$(=num(max(DATE)))"},DAY=,MONTH=>}Sales)

sum({$<DATE={"<=$(=num(max(DATE)-1))"},DAY=,MONTH=>}Sales)

sum({$<DATE={"<=$(=num(max(DATE)-2))"},DAY=,MONTH=>}Sales)

sum({$<DATE={"<=$(=num(max(DATE)-3))"},DAY=,MONTH=>}Sales)

sum({$<DATE={"<=$(=num(max(DATE)-4))"},DAY=,MONTH=>}Sales)

.... and so on.

Regards,

Udit


udit_kumar_sana
Creator II
Creator II

Sorry i forget to tell regarding summation

If u need to  get sum of past 10 days then either manually create data for each 10 days from the expressions as mentioned in above post and add them .

or

use the below expressions:

=

sum({$<DATE={">=$(=num(max(DATE)-10))<=$(=num(max(DATE)))"},DAY=,Month=>}Sales)

Regards,

Udit