Skip to content
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] Fix read from Oracle Date type value lose time #5814

Merged
merged 2 commits into from
Nov 11, 2023

Conversation

Hisoka-X
Copy link
Member

@Hisoka-X Hisoka-X commented Nov 8, 2023

Purpose of this pull request

This PR fix read from Oracle Date type value lose time part value. It cause by wrong type convert, before this PR, SeaTunnel convert Date type to SeaTunnel LOCAL_DATE_TYPE, this PR change it to LOCAL_DATE_TIME_TYPE.

Does this PR introduce any user-facing change?

Yes, the wrong behavior will not existed.

How was this patch tested?

add new test.

Check list

@Hisoka-X Hisoka-X added this to the 2.3.4 milestone Nov 8, 2023
@Hisoka-X Hisoka-X added the bug label Nov 8, 2023
@@ -128,7 +128,6 @@ public SeaTunnelDataType<?> toSeaTunnelType(
case ORACLE_XML:
return BasicType.STRING_TYPE;
case ORACLE_DATE:
return LocalTimeType.LOCAL_DATE_TYPE;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there compatibility with older versions?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is compatible for the reading data end, but may not be compatible for the downstream writing data end because the data content has changed. But the purpose of this PR is to correct previous wrong behavior.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@hailin0 hailin0 merged commit 2d704e3 into apache:dev Nov 11, 2023
8 checks passed
@Hisoka-X Hisoka-X deleted the fix-oracle-date-type branch November 24, 2023 05:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants