Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hy!
I have da date string Week-Year (example 15-2021) and values.
Now I need the value 5 Weekes ago.
This is no problem during th year, but I have problem with the turn of the year
Example
2-2021
I need the value from the week 50-2020 (5 weeks ago)
Do you have any idea (need it in the script, not in a chart)?
Thx
Assuming you have a field named Week_Year. Then you can accomplish this by this expression.
Week(MakeWeekDate(SubField(Week_Year,'-',2),SubField(Week_Year, '-',1))-5*7)
&'-'&
WeekYear(MakeWeekDate(SubField(Week_Year,'-',2),SubField(Week_Year,'-',1))-5*7)
It can be used both in the script and as an expression in the front end.
Assuming you have a field named Week_Year. Then you can accomplish this by this expression.
Week(MakeWeekDate(SubField(Week_Year,'-',2),SubField(Week_Year, '-',1))-5*7)
&'-'&
WeekYear(MakeWeekDate(SubField(Week_Year,'-',2),SubField(Week_Year,'-',1))-5*7)
It can be used both in the script and as an expression in the front end.
Perfekt! Thx for your help 🙂