Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Extract date from a week?

Hello,

I'm currently working on data where the date is set as week 1 week 2 week 3 (week 1 begining January first). Id like to know if there is a way to transform this data into dates when I load my table?

This is what my loading script looks like atm:

     CrossTable(Weeks, Load, 4)

     LOAD [People]    as [Collab],

          [Center],

          [Projet],

          [Activity],

          Week1,

          Week2,

          Week3,

          Week4,

          Week5

          ......

Thanks in advance for any help concerning this matter!

1 Solution

Accepted Solutions
Not applicable
Author

Hi Loic,

i don't remember if such a function exists but what you can do is build a date from 01/01/13 (Date1)

using date + Nb

Where Nb is the number of days according to your week n° like

date = $(Date1) + ((WeekNo-1) * 7) + 1

regards

Chris

View solution in original post

4 Replies
Not applicable
Author

Hi Loic,

i don't remember if such a function exists but what you can do is build a date from 01/01/13 (Date1)

using date + Nb

Where Nb is the number of days according to your week n° like

date = $(Date1) + ((WeekNo-1) * 7) + 1

regards

Chris

Not applicable
Author

Hi,

just take the week number 1,2,3...... from week1,week2,week3,..... and multiply with 7 and add with jan 1.

Not applicable
Author

Oh I didnt realise I could manipulate Dates so easily since I'm begining with Click view. Thanks for this answer!

Not applicable
Author

Same answer at almost the same time as christian, thanks both!