Nice question, I checked the answer just to be sure and realized that a nice wrong answer would have been June 6, 2079 which is the limit for smalldatetime. Mostly to include the reference in the explanation.
Nice detail on the year 2038 problem.
Luis C.How to post data/code on a forum to get the best help: Option 1 / Option 2
Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?