What I want is:
1. When a transaction is performed, the current time is recorded
2. Timezone info is also stored so that the time will be converted automatically based on client-side timezone
So TIMESTAMP sounds like a perfect choice for me, but it turns out that the range is too small (1970-2038) for applications that need to stand long. So I wonder how I can get around this limitation. I know that DATETIME has a much wider range, but it doesn’t seem to fulfill requirement no. 2, may I have your ideas?
You probably need to store the timezone offset in a separate field and store using a
DATETIMEthat’s represented in UTC as you should for all dates and times unless you have a very good reason.The full time-zone name would need to be expressed because the time-zone offset alone is not as meaningful. For example, -0400 could refer to Eastern Daylight Time or Central Standard Time.