All Products
Search
Document Center

DataWorks:OceanBase

Last Updated:Mar 27, 2026

Use OceanBase nodes in DataWorks to write SQL tasks, schedule them to run automatically, and integrate them with other pipeline jobs. This topic walks you through creating a node, writing SQL, configuring a schedule, debugging, and publishing to production.

Background information

OceanBase is a distributed relational database that is independently developed by Ant Group and Alibaba. It provides strong consistency, high availability, high performance, online scaling, low costs, and high compatibility with SQL standards and mainstream relational databases. For more information, see What is OceanBase.

Prerequisites

Before you begin, make sure you have:

  • A Business Flow. DataStudio organizes all development work inside Business Flows. Create one before adding any nodes. For more information, see Create a workflow.

  • An OceanBase data source (JDBC only). Add your OceanBase database as a data source in DataWorks so the node can connect to it. OceanBase nodes only support data sources created with a Java Database Connectivity (JDBC) connection string. For more information, see Data Source Management and ApsaraDB for OceanBase data sources.

  • Network connectivity between the data source and resource group. Confirm the resource group you plan to use can reach the OceanBase data source. For more information, see Network connection solutions.

  • (RAM users only) Workspace membership with the Develop or Workspace Administrator role. Add the RAM user to the workspace and assign the Develop or Workspace Administrator role. Grant the Workspace Administrator role with caution — it carries elevated privileges. For more information, see Add members to a workspace.

Supported regions

China (Hangzhou), China (Shanghai), China (Beijing), China (Shenzhen), China (Chengdu), China (Hong Kong), Singapore, Malaysia (Kuala Lumpur), Germany (Frankfurt), US (Silicon Valley), and US (Virginia).

Step 1: Create an OceanBase node

  1. Go to the DataStudio page. Log on to the DataWorks console. In the top navigation bar, select the target region. In the left-side navigation pane, choose Data Development and O&M > Data Development. Select the target workspace from the drop-down list and click Go to Data Development.

  2. Right-click the target workflow and choose New Node > Database > OceanBase.

  3. In the Create Node dialog box, enter a Name for the node and click Confirm. The node editor opens. Proceed to develop and configure the task.

Step 2: Develop an OceanBase task

Select a data source

If the workspace has multiple OceanBase data sources, select the one to use on the node editing page. If only one data source exists, it is used automatically.

Note

OceanBase nodes only support data sources created with a JDBC connection string.

Write SQL code

In the code editor, write the SQL statements for the task. The following is a basic example.

SELECT * FROM usertablename;

Use scheduling parameters

Scheduling parameters let you pass dynamic values into SQL at runtime — useful for date-partitioned queries or environment-specific values. Define a variable in your SQL using ${variable_name} syntax, then assign its value on the Schedule tab under Scheduling Parameters.

SELECT '${var}'; -- Replace ${var} with a scheduling parameter value.

For the full list of supported variable formats, see Supported formats of scheduling parameters. For step-by-step configuration, see Configure and use scheduling parameters.

Step 3: Configure task scheduling

Click Scheduling Configuration on the right panel and set the scheduling properties.

Note

Configure both Rerun Property and Upstream Dependent Node before submitting.

For a full reference of scheduling options, see Overview.

Step 4: Debug the task

  1. (Optional) Select a debugging resource group and assign parameter values. Click the 高级运行 icon in the toolbar. In the Parameters dialog box, select a resource group. Assign values to any scheduling parameters for debugging. For more information about parameter assignment logic, see Task debugging process.

  2. Save and run the task. Click the 保存 icon to save, then click the 运行 icon to run.

  3. (Optional) Run a smoke test. A smoke test validates execution in the development environment without affecting production. Run one during or after submission to verify end-to-end behavior before the task goes live. For more information, see Perform smoke testing.

Step 5: Submit and publish the task

  1. Click the 保存 icon to save the node.

  2. Click the 提交 icon to submit the node. In the Submit dialog box, enter a Change Description and review the code review settings.

    Note

    When code review is enabled, an approver must sign off before the task can be published. For more information, see Code review.

  3. For standard mode workspaces, click Publish in the upper-right corner to deploy the task to production. For more information, see Publish tasks.

What's next

After publishing, the task runs on its configured schedule. To monitor execution, click O&M in the upper-right corner of the node tab to open Operation Center, where you can view the status of each scheduled run. For more information, see Manage recurring tasks.