Sink plugin: Hive [Spark]
Write Rows to Apache Hive.
name | type | required | default value |
---|---|---|---|
sql | string | no | - |
source_table_name | string | no | - |
result_table_name | string | no | - |
sink_columns | string | no | - |
save_mode | string | no | - |
partition_by | Array[string] | no | - |
Hive sql:the whole insert data sql, such as insert into/overwrite $table select * from xxx_table
, If this option exists, other options will be ignored.
Datasource of this plugin.
The output hive table name if the sql
option doesn't specified.
Same with option spark.mode
in Spark, combined with result_table_name
if the sql
option doesn't specified.
Specify the selected fields which write to result_table_name, separated by commas, combined with result_table_name
if the sql
option doesn't specified.
Hive partition fields, combined with result_table_name
if the sql
option doesn't specified.
sink {
Hive {
sql = "insert overwrite table seatunnel.test1 partition(province) select name,age,province from myTable2"
}
}
sink {
Hive {
source_table_name = "myTable2"
result_table_name = "seatunnel.test1"
save_mode = "overwrite"
sink_columns = "name,age,province"
partition_by = ["province"]
}
}