Get week starting date from weeknum and year in R
By : user3784018
Date : March 29 2020, 07:55 AM
I wish this helpful for you I'm looking for a function that will get year + week number + Week day, and return a date, for example: , Using strptime: code :
strptime("2015Monday23", "%Y%A%U")
# [1] "20150608"
strptime(paste0(2015, "Monday", 23), "%Y%A%U")

Weeknum that doesn't start from 1st every year
By : Jessica Laura Sendal
Date : October 28 2020, 07:41 AM
Hope this helps How can i start weeknum from first week in 2018 and go on through 2019, 2020, 2021, 2022... without starting the count from 1 every year. Ex: if 2018 has 44 weeks i want the weeknum(112019) to return 45 not 1 and so on. , If you Week starts on Monday use: code :
=INT((A1"1/1/2018")/7)+1
=INT((A1"1/1/2018"+1)/7)+1

DAX WeekNum for more than 1year?
By : codestorm
Date : March 29 2020, 07:55 AM
seems to work fine You could concatenate your YEAR() and WEEKNUM() results in a single column like this: code :
WeekNum =
CONCATENATE ( WEEKNUM ( 'Calendar'[Date] ), YEAR ( 'Calendar'[Date] ) )
WeekNum =
CONCATENATE (
WEEKNUM ( 'Calendar'[Date] ),
CONCATENATE ( "  ", YEAR ( 'Calendar'[Date] ) )
)

Oracle  How to get date from YEAR, WEEKNUM and WEEKDAY?
By : Joyce
Date : March 29 2020, 07:55 AM
hope this fix your issue I think there is no builtin function for this, you will have to build one on your own. below is one of the solutions you can make use of. code :
WITH FUNCTION getDate(p_year IN NUMBER, p_weeks IN NUMBER, p_day in NUMBER) RETURN DATE
IS
v_tmp date;
v_day number;
BEGIN
v_tmp := to_date('01/01/'to_char(p_year),'dd/mm/yyyy');
v_day := to_char(v_tmp,'D');
RETURN v_tmp+(p_weeks1)*7+p_day(v_day)+1;
END;
SELECT getDate(2019,22,2)
FROM DUAL;
/

How to rollover WeekNum If year does not start on a specific weekday (Like Friday)
By : user3555179
Date : March 29 2020, 07:55 AM
Does that help I figured out a way to achieve my end result. But I know there is still better way to do same thing and hence I am keeping this question open for better approach. Here is what I did: 1. Retrieve MONTH, DAY and WEEKDAY from given date code :
Range("AW5:AW" & FilterDataLastRow).Formula = "=MONTH(RC[6])"
Range("AX5:AX" & FilterDataLastRow).Formula = "=DAY(RC[5])"
Range("AY5:AY" & FilterDataLastRow).Formula = "=WEEKDAY(RC[4],16)"
For i = 5 To FilterDataLastRow
' Check for records with Month = 1 And DAY is 16 and WEEKDAY < 6
If Range("AW" & i).Value = 1 And Range("AX" & i).Value < 7 Then
CurrYear = Year(Range("BC" & i).Value)
PrevYear = CurrYear  1
PrevYearLastDay = "12/31/" & PrevYear
Range("AV" & i).Value = PrevYearLastDay
'Get the Day of Weel on 31st December of Previous Year
Range("AU" & i).Value = "=WEEKDAY(RC[1],16)"
'Calculate Number of Days remaining for new week to start
DaysRemForNewWeek = 8  Range("AU" & i).Value
'Calculate Date of First Friday of Current Year
Range("AT" & i).Value = PrevYearLastDay + DaysRemForNewWeek
'Compare all the dates prior to first Friday and rollover WeekNum from last year for these dates
If Range("BC" & i).Value < Range("AT" & i).Value Then
Range("AZ" & i).Formula = "=(TEXT(RC[4],""yyyy""))&(TEXT(WEEKNUM(RC[4],16),""00""))"
Else
Range("AZ" & i).Formula = "=(TEXT(RC[3],""yyyy""))&(TEXT(WEEKNUM(RC[3],16),""00""))"
End If
Else
Range("AZ" & i).Formula = "=(TEXT(RC[3],""yyyy""))&(TEXT(WEEKNUM(RC[3],16),""00""))"
End If
Next i

