Last Modified Date: 05 Dec 2019
- Select Analysis > Create Calculated Field
- In the Calculated Field dialog box that opens, do the following, and then click OK:
- Name the calculated field. In this example, the calculated field is named "Date".
- In the formula field, create a calculation similar to the following:
DATEADD( 'week', INT( RIGHT( [Date], 2 ) ) -1, DATE( "1/1/" + LEFT( [Date], 4 )))
Cause"Week number" is not a commonly recognized date format.
Additional InformationIn the above calculation, the DATE() function converts the string year data into a date format. The DATEADD() function then adds on the number of weeks. By default the DATE() function returns the first week of the year so adding week number "01" shifts all the weeks by one, which is why we subtracted one from week number.
Please note, the above calculation assumes all of the week numbers will be two digits.
Discuss this article...
Thank you for providing your feedback on the effectiveness of the article.
Open new Case
Training and Tutorials