All Products
Search
Document Center

Dataphin:Configure the KingbaseES output component

Last Updated:Jun 23, 2026

The KingbaseES output component writes data to a KingbaseES data source. After you configure the source data source, configure the KingbaseES output component to specify the target data source for writing data.

Prerequisites

Procedure

  1. In the top navigation bar of the Dataphin homepage, choose Develop > Data Integration.

  2. In the top navigation bar of the Integration page, select Project (In Dev-Prod mode, you need to select Environment).

  3. In the navigation pane on the left, click Batch Pipeline, and then click the offline pipeline that you want to develop in the Batch Pipeline list to open the configuration page of the offline pipeline.

  4. Click Component Library in the upper-right corner of the page to open the Component Library panel.

  5. In the navigation pane on the left of the Component Library panel, select Outputs, find the KingbaseES component in the output component list on the right, and drag the component to the canvas.

  6. Click and drag the image icon of the target input, transform, or flow component to connect it to the current KingbaseES output component.

  7. Click the image icon on the KingbaseES Output component card to open the KingbaseES Output Configuration dialog box.image

  8. In the KingbaseES Output Configuration dialog box, configure the parameters.

    Parameter

    Description

    Basic Settings

    Step Name

    The name of the KingbaseES output component. Dataphin automatically generates a step name that you can modify. The name must meet the following requirements:

    • It can contain only Chinese characters, letters, underscores (_), and digits.

    • It cannot exceed 64 characters in length.

    Datasource

    The dropdown list displays all KingbaseES data sources, regardless of whether you have write-through permission. Click the image icon to copy the data source name.

    Table

    Select the target table for output data. You can enter a keyword to search for a table, or enter the exact table name and click Exact Match. After you select a table, the system automatically checks the table status. Click the image icon to copy the name of the selected table.

    Loading Policy

    Select a policy for writing data to the target table.

    • Append Data (insert Into): When a primary key or constraint violation occurs, a dirty data error is reported.

    • Update On Primary Key Conflict (on Conflict Do Update Set): When a primary key or constraint violation occurs, the data of the mapped fields is updated on the existing record.

    Write-through

    The KingbaseES primary key update syntax is not atomic. If the data to be written has duplicate primary keys, enable write-through. Otherwise, parallel writing is used, which offers better performance.

    Note

    This parameter can be configured only when Update on Primary Key Conflict is selected for Loading Policy.

    Batch Write Size (optional)

    The maximum data size per write batch. The system writes data when either this limit or the Batch Write Count limit is reached. The default value is 32M.

    Batch Write Count (optional)

    The maximum number of records per write batch. The default value is 2048. The system writes data when either the Batch Write Count or Batch Write Size limit is reached.

    • When the accumulated data reaches either limit, the system immediately writes the batch to the destination.

    • We recommend setting the batch write size to 32 MB and adjusting the batch write count based on the actual record size. For example, if a single record is about 1 KB, set the batch write size to 16 MB and the batch write count to a value greater than 16384 (16 MB / 1 KB), such as 20000. The system then triggers batch writing when the accumulated data reaches 16 MB.

    Prepare Statement (optional)

    The SQL script to be executed on the database before data import.

    For example, to ensure continuous service availability, you can create a target table Target_A before writing, write data to Target_A, then rename the active Service_B table to Temp_C, rename Target_A to Service_B, and delete Temp_C.

    Post Statement (optional)

    The SQL script to be executed on the database after data import.

    Field Mapping

    Input Fields

    Lists the input fields from the upstream input component.

    Output Fields

    Displays the output fields. You can perform the following operations:

    • Field Management: Click Field Management to select output fields.

      image

      • Click the gaagag icon to move Selected Input Fields to Unselected Input Fields.

      • Click the agfag icon to move Unselected Input Fields to Selected Input Fields.

    • Batch Add: Click Batch Add to configure in JSON, TEXT, or DDL format in batches.

      • Configure in JSON format, for example:

        // Example:
        [{
          "name": "user_id",
          "type": "String"
         },
         {
          "name": "user_name",
          "type": "String"
         }]
        Note

        The `name` parameter specifies the name of the imported field, and the `type` parameter specifies the data type of the field after it is imported. For example, "name":"user_id","type":"String" imports the field named `user_id` and sets its data type to String.

      • Configure in TEXT format, for example:

        // Example:
        user_id,String
        user_name,String
        • The row delimiter is used to separate the information of each field. The default is a line feed (\n). Line feed (\n), semicolon (;), and period (.) are supported.

        • The column delimiter is used to separate the field name and field type. The default is a comma (,).

      • Configure in DDL format, for example:

        CREATE TABLE tablename (
            id INT PRIMARY KEY,
            name VARCHAR(50),
            age INT
        );
    • Create Output Field: Click +Create Output Field, fill in Column and select Type as prompted. After configuring the current row, click the image icon to save.

    Mapping

    Maps input fields from the upstream component to the target table fields. Mapping supports Same Row Mapping and Same Name Mapping.

    • Same Name Mapping: Maps fields with the same name.

    • Same Row Mapping: Maps fields by their row position, even if the field names differ between the source and target tables.

  9. Click OK to complete the property configuration of the KingbaseES Output Component.