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

[Improve][[Jdbc]sink sql support custom field.(#6515) #6525

Merged
merged 7 commits into from
Jun 15, 2024
Merged

Conversation

rtyuy
Copy link
Contributor

@rtyuy rtyuy commented Mar 18, 2024

Purpose of this pull request

[Improve][[Jdbc]sink sql support custom field.(#6515)

When the sink columns do not contain all source columns, you can use a named parameter like this:

 query = "INSERT INTO INVER_WORK_ORDER2 (col1,col2,  col3,col4) VALUES(:WORK_ORDER_ID,:WORK_ORDER_NAME,  :CREATE_STAFF_ID,:CREATE_STAFF_NAME)"

Make sure that all named parameters exist in the source column.

Does this PR introduce any user-facing change?

How was this patch tested?

Check list

@Hisoka-X
Copy link
Member

Thanks @rtyuy ! Please add test case. Also please open ci on your fork repository.
image

@rtyuy
Copy link
Contributor Author

rtyuy commented Mar 20, 2024

Thanks @rtyuy ! Please add test case. Also please open ci on your fork repository. image

add test

@Hisoka-X
Copy link
Member

Hisoka-X commented Apr 8, 2024

Thanks @rtyuy for update! Could you add this feature into the jdbc doc? https://github.com/apache/seatunnel/blob/dev/docs/en/connector-v2/sink/Jdbc.md

@Hisoka-X
Copy link
Member

Hisoka-X commented Apr 8, 2024

cc @EricJoy2048 @hailin0

@Hisoka-X Hisoka-X added the feature New feature label Apr 9, 2024
@hailin0
Copy link
Member

hailin0 commented May 30, 2024

@rtyuy

cc @Hisoka-X

Why not use transform to filter fields?

@hailin0
Copy link
Member

hailin0 commented May 30, 2024

Thanks @rtyuy for update! Could you add this feature into the jdbc doc? https://github.com/apache/seatunnel/blob/dev/docs/en/connector-v2/sink/Jdbc.md

cc @rtyuy

@Hisoka-X Hisoka-X merged commit ef3e61d into apache:dev Jun 15, 2024
4 checks passed
chaorongzhi pushed a commit to chaorongzhi/seatunnel that referenced this pull request Aug 21, 2024
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