This site uses different types of cookies, including analytics and functional cookies (its own and from other sites). To change your cookie settings or find out more, click here. If you continue browsing our website, you accept these cookies.
There are some other good leads to a solution above. It all depends on how you define the first week of the year, but you can calculate a formula to calculate the Monday of the week, order them, then add a record ID. That will give you a week number.
To calculate the Monday of the week, you can use a formula like the one below. This is SQL, but you should be able to easily convert it into an Alteryx formula.
Cast(calendar_date - ((calendar_date- Cast('1900-01-01' As Date)) Mod 7 ) As Date) As monday_of_week
Presumes current year by using DateTimeNow() but that could be replaced with an date in a column to get the year of it instead. [week] is then the numeric week number. Using these offsets, Sunday is first day.