[INLONG-6507][Sort] Convert date to timestamp in oracle connector#6508
Merged
dockerzhang merged 7 commits intoapache:masterfrom Nov 15, 2022
Merged
[INLONG-6507][Sort] Convert date to timestamp in oracle connector#6508dockerzhang merged 7 commits intoapache:masterfrom
dockerzhang merged 7 commits intoapache:masterfrom
Conversation
yunqingmoswu
approved these changes
Nov 11, 2022
healchow
approved these changes
Nov 11, 2022
Contributor
|
Maybe, PR description is not consistent with modification of code |
EMsnap
reviewed
Nov 11, 2022
Member
EMsnap
left a comment
There was a problem hiding this comment.
Please check the mysql connector for the date and timestamp data.
Contributor
Author
Yes, the oracle connector handles date and timestamp data like the mysql connector. |
Contributor
Author
More details have been added to the PR description. |
gong
reviewed
Nov 12, 2022
.../java/org/apache/inlong/sort/cdc/oracle/debezium/table/RowDataDebeziumDeserializeSchema.java
Outdated
Show resolved
Hide resolved
Contributor
@e-mhui good. |
gong
approved these changes
Nov 14, 2022
EMsnap
approved these changes
Nov 15, 2022
dockerzhang
pushed a commit
that referenced
this pull request
Nov 15, 2022
liaorui
pushed a commit
to liaorui/inlong
that referenced
this pull request
Feb 20, 2023
This file contains hidden or 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
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.
Prepare a Pull Request
[INLONG-6507][Sort] Convert date to timestamp in oracle connector
Motivation
In debezium, the oracle date type will be read as the int64 type, but the oracle date type mapping is the debezium timestamp type, and the debezium timestamp type is the string format of date-time. So, we need to convert the int64 to the string format of date-time.
Modifications
When parsing field value, if the field schema is date or timestamp type, we need to convert the filed value from the number of milliseconds to the string format of date-time. The main logic is as follows: