[sqlserver] Fix timestamp type parse of sqlserver#2708
[sqlserver] Fix timestamp type parse of sqlserver#2708GOODBOY008 merged 1 commit intoapache:masterfrom
Conversation
|
Hi, @GOODBOY008 , I have modified how to parse timestam_ltz value in testTemporalTypesWithTimeZone. Do you mean that TO_TIMESTAMP(val_datetimeoffset) ? A TIMESTAMP_LTZ value can be parsed to different TIMESTAMP values in in different timezone. |
a93a7db to
3a09769
Compare
3a09769 to
8a3d953
Compare
| } | ||
|
|
||
| @Test | ||
| public void testTimeZone_ltz2ntz() throws Exception { |
9b3b6f9 to
60e681f
Compare
TimestampData.fromLocalDateTime(
LocalDateTime.ofInstant(instant, serverTimeZone));@GOODBOY008 , LocalDateTime.ofInstant(instant, serverTimeZone)) use serverTimeZone, while TimestampData.fromLocalDateTime use JVM's default timezone. If this two timezones are not same, time will change. And I design a test with different timezones:
By the way, MSSQL_SERVER_CONTAINER can not run on my m2 Macbook, it's hard to develop server-sql cdc. |
60e681f to
668b803
Compare
GOODBOY008
left a comment
There was a problem hiding this comment.
@loserwang1024 Great catch , Thanks for your contribution. LGTM
Fix #2637