Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I need a reference date which eqauls last week in my set ananlysis.
Like for example:
sum({$<ReferenceDate = {'24/07/2016'}>} _Saldo) - sum({$<VervallenSegmStatus = {'Actueel'}, ReferenceDate = {'24/07/2016'}>} _Saldo)
But the date which is now fixed should be able to change.
Like for example:
sum({$<ReferenceDate = {"week(ReferenceDate) -1"}>} _Saldo) - sum({$<VervallenSegmStatus = {'Actueel'}, ReferenceDate = {"week(ReferenceDate) -1"}>} _Saldo)
So the code in bold is not working at the moment.
Can someone help me with this problem?
Thanks!
You can discard my last question. I solved the problem.
Instead of using ReferenceDate, I made a ReferenceWeek in my script like this:
week(ReferenceDate) as ReferenceWeek
and then I used following expression:
=sum({$<ReferenceWeek = {"$(=ReferenceWeek -1)"}, ReferenceDate = >} _Saldo)
With this code I got it working!
use this
ReferenceDate - 7
or
weekstart(ReferenceDate -7)
Hello Rodrigo,
Thanks for your answer!
But can you give me some more information because I can't get it working.
So you mean {"week(ReferenceDate) -7"} ? Because like this it doesn't work.
You can discard my last question. I solved the problem.
Instead of using ReferenceDate, I made a ReferenceWeek in my script like this:
week(ReferenceDate) as ReferenceWeek
and then I used following expression:
=sum({$<ReferenceWeek = {"$(=ReferenceWeek -1)"}, ReferenceDate = >} _Saldo)
With this code I got it working!