Skip to content

Commit 836cad8

Browse files
authored
Merge pull request #3092 from dolthub/elianddb/fix-locale-issue
add UTC() to unix time min and max Timestamp
2 parents 50fea41 + 0fc726a commit 836cad8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sql/types/datetime.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,10 +46,10 @@ var (
4646
datetimeTypeMinDatetime = time.Date(1000, 1, 1, 0, 0, 0, 0, time.UTC)
4747

4848
// datetimeTypeMaxTimestamp is the maximum representable Timestamp value, MYSQL: 2038-01-19 03:14:07.999999 (microseconds)
49-
datetimeTypeMaxTimestamp = time.Unix(math.MaxInt32, 999999000)
49+
datetimeTypeMaxTimestamp = time.Unix(math.MaxInt32, 999999000).UTC()
5050

5151
// datetimeTypeMinTimestamp is the minimum representable Timestamp value, MYSQL: 1970-01-01 00:00:01.000000 (microseconds)
52-
datetimeTypeMinTimestamp = time.Unix(1, 0)
52+
datetimeTypeMinTimestamp = time.Unix(1, 0).UTC()
5353

5454
datetimeTypeMaxDate = time.Date(9999, 12, 31, 0, 0, 0, 0, time.UTC)
5555

0 commit comments

Comments
 (0)