My comment to which you seem to have taken objection merely reflects the fact that as a fulltime teacher, solutions you post may be examples of how something could be done rather than something you used in "real life," especially in a case like this that had a piece missing.
Surely you remember that your posted solution used null placeholders and needed a subsequent workaround to handle null values. I had assumed that you were fulfilling your role as teacher and showing how something might be achieved rather than posting code you'd actually used. The alternative would be to claim that you had no experience with datetime fields (which definitely need null values) which would indeed have been an insult.
Say, we're both in the PA Crew these days. Peace.
"... They ne'er cared for us
yet: suffer us to famish, and their store-houses
crammed with grain; make edicts for usury, to
support usurers; repeal daily any wholesome act
established against the rich, and provide more
piercing statutes daily, to chain up and restrain
the poor. If the wars eat us not up, they will; and
there's all the love they bear us."
-- Shakespeare: Coriolanus, Act 1, scene 1