zhilinli123 commented on PR #4826:
URL: https://github.com/apache/seatunnel/pull/4826#issuecomment-1562170054
```
hive Source:
create table test3 (
name string,
age int,
emails ARRAY<STRING>,
phones map<STRING, string>
);
INSERT INTO TABLE test3
VALUES ('list',12,array("[email protected]", "[email protected]",
"[email protected]"), map('home', "13987167117", 'office', "15178968888"));
hive Sink:
create table test3_sink (
name string,
age int,
emails ARRAY<STRING>,
phones map<STRING, string>
);
Conf :
env {
# You can set spark configuration here
execution.parallelism = 1
job.mode = "BATCH"
}
source {
Hive {
table_name = "default.test3"
metastore_uri = "thrift://localhost:9083"
result_table_name = "user"
}
}
transform {
# If you would like to get more information about how to configure
seatunnel and see full list of transform plugins,
# please go to https://seatunnel.apache.org/docs/category/transform
Replace {
source_table_name = "user"
result_table_name = "user_1"
replace_field = "name"
pattern = "s"
replacement = "w"
is_regex = true
replace_first=true
}
}
sink {
# Console{ source_table_name = "user" }
Hive {
source_table_name = "user_1"
table_name = "default.test3_sink"
metastore_uri = "thrift://localhost:9083"
}
}
table result test3_sink :
liwt 12 ["[email protected]","[email protected]","[email protected]"]
{"office":"15178968888","home":"13987167117"}
```
<img width="1313" alt="image"
src="https://github.com/apache/seatunnel/assets/76689593/5260d904-7c7f-4066-b9a0-660fec3646ea">
--
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]