Write to a data table

Updated at:

This topic describes how to use the Write to Data Table operator.

Purpose

The Write to Data Table operator writes data from upstream nodes to a specified data table.

Scenarios

Compute link

Compute engine

Supported

Offline

MaxCompute

Yes

Hive

Yes

HiveStorage

Yes

RDS/MySQL

Yes

Usage instructions

Offline link

Input node

Displays the fields that are passed from the upstream node to the current node.

Data synchronization

Configure the target data table to which the upstream output data is written.

Compute resource type

Select the type of the target data source. For a list of supported target data source types, see Scenarios.

Target data source

Select the target data source.

Target data table

Select the name of the table in the target data source.

Lifecycle (optional)

Set the retention period in days for the target table. If you do not set this parameter, the default retention period is 1 day.

Note

The lifecycle determines when the target table is automatically deleted.

For example, if you set the lifecycle to 1 day, the table is deleted after one day. The table is not deleted at the exact 24-hour mark, but can be deleted at any time on its expiration date.

Field list

Configure the list of fields to output to the target table.

In the field list, you can modify the details of the upstream output fields, such as renaming fields or modifying comments.

Synchronization mode

Full synchronization: Clears all existing data from the target table and then inserts the new data.

Incremental synchronization: Retains the existing data in the target table and appends the new data.

Partition synchronization: Overwrites a specified partition in the target table with new data. This mode is available only for compute resources that support partitions.

Note

If a table with the same name as the target table exists in the target compute engine, the synchronization runs as expected if the table structures match. If the structures do not match, an exception is thrown.