Use Date/Time Fields Instead of Date Fields Wherever Possible

Q: “What’s wrong with Date fields?”

A: Imprecision! If I set a Date field to January 1st, I’m assigning my coworkers unintended homework: start of day? end of day? and is that January 1st for me, or them?

Without a timestamp, a single date can span a 5-day (or 120-hour) stretch of time (!):

  • “Jan 1st” can go as far back as “Dec 30th”: 2025-01-01 at 00:00 in Kiribati corresponds to 2024-12-30 at 23:00 on Midway
  • “Jan 1st” can go as far forward as “Jan 3rd”: 2025-01-01 at 23:59 on Midway corresponds to 2025-01-03 at 00:59 in Kiribati

( . . . ok, I don’t know how many folks have coworkers in Midway or Kiribati. But I definitely have coworkers across the globe.)

I bet you good money the folks at Salesforce wish they’d implemented “Close Date” as “Close Date/Time” 😝

props to the Time Zone Map

Leave a comment