Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Week(y) over week(y-1) in line chart

Hello all,

I'm stuck on this problem for a while now.

I Want to create a line chart of the evolution vs same week year -1.

For that I created a kind of master calendar (it runs until today):

Capture1QV.PNG

Period ID is autogenerated field with autonumber function on Period.

then I created the two following formulas in order to calculate Sales for Year Y and Year Y-1

For Year Y:

sum({<PeriodID={"<=$(=Max(PeriodID))"}, Year = , Month =, Quarter=,Week= >}Volume)

For Year Y-1

Above(sum({<PeriodID={"<=$(=Max(PeriodID)-52)"}, Year =  , Month =, Quarter=,Week= >}Volume),52)


and after I made First fomula over the second -1

This solution solution using above work in some cases, but it doesn't work as soon as I want to have the split by a second dimension in my chart.

What I want Is Something as the folow where each line are differents Value of the same field ( As countries for example):

Capture2QV.PNG

Hope I have been clear about my problem.

Just for information I m working on Peersonal edition and Can't open qvw files from the forum .

Thanks all for your help

Jonathan

0 Replies