-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix timestamp handling in JDBC connectors #495
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 tasks
cc @vincentpoon |
findepi
force-pushed
the
findepi/pgtimestamp
branch
2 times, most recently
from
March 18, 2019 15:55
09b71dc
to
aeb4863
Compare
Thanks, I learned quite a bit from looking over this PR. I'll update my PRs accordingly. |
findepi
force-pushed
the
findepi/pgtimestamp
branch
7 times, most recently
from
March 21, 2019 10:12
e0cc8a1
to
3fbb007
Compare
ready for review |
Typo |
electrum
approved these changes
Mar 26, 2019
presto-base-jdbc/src/main/java/io/prestosql/plugin/jdbc/StandardColumnMappings.java
Outdated
Show resolved
Hide resolved
presto-base-jdbc/src/main/java/io/prestosql/plugin/jdbc/StandardColumnMappings.java
Outdated
Show resolved
Hide resolved
presto-base-jdbc/src/main/java/io/prestosql/plugin/jdbc/StandardColumnMappings.java
Show resolved
Hide resolved
presto-base-jdbc/src/main/java/io/prestosql/plugin/jdbc/StandardColumnMappings.java
Outdated
Show resolved
Hide resolved
presto-base-jdbc/src/main/java/io/prestosql/plugin/jdbc/StandardColumnMappings.java
Outdated
Show resolved
Hide resolved
presto-postgresql/src/test/java/io/prestosql/plugin/postgresql/TestPostgreSqlTypeMapping.java
Outdated
Show resolved
Hide resolved
presto-postgresql/src/test/java/io/prestosql/plugin/postgresql/TestPostgreSqlTypeMapping.java
Outdated
Show resolved
Hide resolved
presto-postgresql/src/test/java/io/prestosql/plugin/postgresql/TestPostgreSqlTypeMapping.java
Outdated
Show resolved
Hide resolved
presto-postgresql/src/test/java/io/prestosql/plugin/postgresql/TestPostgreSqlTypeMapping.java
Outdated
Show resolved
Hide resolved
presto-postgresql/src/test/java/io/prestosql/plugin/postgresql/TestPostgreSqlTypeMapping.java
Outdated
Show resolved
Hide resolved
`java.sql.Timestamp` (used by Tempto and Presto JDBC connectors), Joda Time and Java Time differ in their time zone offset information for historic dates. We cannot guarantee correct results for these dates. See 42c3375 for a similar change for date values.
The existing `timestamp` handling was not correct, regardless of timestamp semantics. This commit introduces - as good as possible timestamp handling that is guaranteed to work (using `java.sql.Timestamp`) - timestamp handling that can work, if only driver supports `LocalDateTime` - tests for PostgreSQL
ac |
findepi
force-pushed
the
findepi/pgtimestamp
branch
from
March 27, 2019 21:04
3fbb007
to
e63f768
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The existing
timestamp
handling was not correct, regardless oftimestamp semantics.
This commit introduces
(using
java.sql.Timestamp
)LocalDateTime