Tsukasa007 commented on issue #9127:
URL: https://github.com/apache/seatunnel/issues/9127#issuecomment-3100516333
Hello, I'm also encountering this issue. Here is my job configuration. Could
you take a look? The fields in the automatically created tables are garbled.
env {
parallelism = 1
job.mode = "STREAMING"
checkpoint.interval = 10000
}
source {
MySQL-CDC {
base-url =
"jdbc:mysql://172.16.21.169:3307/czhl_new_column?characterEncoding=UTF-8"
username = "root"
password = "123"
database-names = ["czhl_new_column"]
table-names = ["czhl_new_column.def_user"]
startup.mode = "initial"
plugin_output = "source1"
}
}
transform {
Sql {
query = "SELECT id as `user_id`, username as `user_username拉阿拉`,
nick_name as `user_nick_name`, mobile as `user_mobile` FROM dual"
plugin_input = "source1"
plugin_output = "transform1"
}
}
sink {
jdbc {
plugin_input = "transform1"
url =
"jdbc:mysql://172.16.21.169:3307/seatunnel_sync_test?useUnicode=true&characterEncoding=UTF-8&rewriteBatchedStatements=true"
driver = "com.mysql.cj.jdbc.Driver"
user = "root"
password = "123"
generate_sink_sql = true
database = "seatunnel_sync_test"
table = "user_employee"
primary_keys = ["user_id"]
schema_save_mode = "CREATE_SCHEMA_WHEN_NOT_EXIST"
data_save_mode = "APPEND_DATA"
}
}
<img width="845" height="236" alt="Image"
src="https://github.com/user-attachments/assets/94f06df8-4645-4a6c-a031-cda0249951ea"
/>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]