Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello.
i wanted to write a simple expression with set analysis which compares a field with a weeknumber per entry with its former week.
So basically I have a table like this:
Week | Article | Amount
11 | item1 | 10
10 | item 1 | 20
Now i want to put out the difference between these two amounts in another column and wrote something like this:
{<Week= {Week}>}Amount - {<Week= {lastWeek}>}Amount
But this only puts out the difference to the former week if its a positive amount, I'd also like to know if the amount in week 11 was less than in 10, like above in the table, it's negative amount difference.
What am I missing?
(Please note that I created the "lastWeek" field in the load script as following:
[Week] - 1 as lastWeek
Hello,
You can try this :
sum({<Week= {Week}>}Amount) - sum({<Week= {lastWeek}>}Amount)
Hey there,
thanks for the reply.
I tried that before, but this will give me 0 values in every row though.