I have two dates - [Transaction Date] and [Posted Date] in the format of XX/XX/XXXX. I am trying to convert these dates to each have date, month, month year, date month year, etc...
While the below calendar I built works, I do not think it is correct. I need master calendar to show missing dates as well. Is there a better way to write it?
Year(TempDate1) AS [Posted_Year], Month(TempDate1) as [Posted_Month], day(TempDate1) as [Posted_MDay], Week(TempDate1) as [Posted_Week], WeekName(TempDate1) as [Posted_WeekName], Date(MonthStart(TempDate1),'MM-YYYY') as [Posted_YearMonth], //Resident TempCal;
TempDate2 as [Transaction_Date],
Year(TempDate2) AS [Transcation_Year], Month(TempDate2) as [Transaction_Month], day(TempDate2) as [Transaction_MDay], Week(TempDate2) as [Transaction_Week], WeekName(TempDate2) as [Transaction_WeekName], Date(MonthStart(TempDate2),'MM-YYYY') as [Transaction_YearMonth] Resident TempCal;