Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
OmarBenSalem
Partner - Champion II
Partner - Champion II

Getting the diffrence between successive values in a dimension

Hi all,

The question is not that clear but here is what I am trying to do :

I have a dimension called : "weeks" that is specific for the weeks of the year and goes from  1 (first week) to 52 (last week) :1,2,3,4...52

I have an expression "test", each week has its own "test" as a value.

Exp:

Weeks: 1,2,3,4,5,6......,51,52

test:1000,2000,3000,4000,3000,...,2000,1000

I want to have a new expression "delta" which will calculate the difference between each successive weeks (0,1) (1,2) (2,3) and so on :

delta : 1000(1000-0), 1000 (2000-1000), 1000(3000-2000), 1000(4000-3000), -1000(3000-4000)...., -1000(1000-2000)

How to proceed to do so?

It's really kind of an urgent request, hope that you'll be kind enough to help ! Thanks !

Labels (1)
1 Solution

Accepted Solutions
maxgro
MVP
MVP

maybe the

above function

1.png

View solution in original post

2 Replies
maxgro
MVP
MVP

maybe the

above function

1.png

OmarBenSalem
Partner - Champion II
Partner - Champion II
Author

Thank you !!