Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
Is it possible to convert a YYYY-WW date format into a single date? Lets say the last day of that week?
Use MakeWeekDate() function.
Example:
=MakeWeekDate(Left('2013-09',4),Right('2013-09',2),6) // the red '6' tells about the last day of the week, you can modify accordingly.
Hi,
Yes. Consider that the YYYY-WW is the text then you can use the below expression to get the date.
MakeWeekDate(left(Field,4),right(field,2),0)
Here 0 is considered as monday of that week.
Regards,
Kaushik Solanki
Here is one option (vWeek should be a date in YYYY-WW format):
MakeWeekDate(Left(vWeek,4),Right(vWeek,2))
Thank you. I have one problem. Some fields are like this:
2013-2
instead of 2013-02.
Is there a way to exclude the '-' ?
Hi, Tresosco,
suggestion is not bad but num() will not work in this case, but num#() will work.
Regards,
Kaushik Solanki
Yes there is:
MakeWeekDate(SubField('2013-02','-'),SubField('2013-02','-',2))
Would be a negative week number:
MakeWeekDate(left('2013-2',4),Num#(right('2013-2',2)),0) => 10.12.2012
, right .