Converting a date CYYMMDD to and from
Monday, December 15th, 2008I ran into a customer using the old Y2K Date that I hhadn’t seen for a while and thought that I would take a moment to blog how to convert to and from. TO : CASE WHEN SUBSTRING(CAST(dKey_TimeByDay AS VARCHAR),1,1) = 2 THEN ’1′+ SUBSTRING(CAST(dKey_TimeByDay AS VARCHAR),3,6) ELSE ’0′ + SUBSTRING(CAST(dKey_TimeByDay AS VARCHAR),3,6) END [...]