All Products
Search
Document Center

DataWorks:Create and use an AnalyticDB for PostgreSQL node

Last Updated:Apr 15, 2026

Use AnalyticDB for PostgreSQL nodes in DataWorks to develop and periodically schedule AnalyticDB for PostgreSQL tasks and integrate them with other tasks. This topic outlines the workflow for developing a task with an AnalyticDB for PostgreSQL node.

Prerequisites

Background information

AnalyticDB for PostgreSQL nodes connect to the Alibaba Cloud AnalyticDB for PostgreSQL service. For more information, see AnalyticDB for PostgreSQL.

Step 1: Create an AnalyticDB for PostgreSQL node

  1. Go to the DataStudio page.

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

  2. Right-click the target workflow and choose Create Node > AnalyticDB for PostgreSQL > ADB for PostgreSQL.

  3. In the Create Node dialog box, enter a Name for the node and click OK. After the node is created, you can develop and configure the task in the new node.

Step 2: Develop an AnalyticDB for PostgreSQL task

(Optional) Select a computing resource

If your workspace has multiple AnalyticDB for PostgreSQL computing resources, you must select the appropriate one on the node's editor page. If only one computing resource is available, it is selected by default.

Write SQL code

In the code editor of the AnalyticDB for PostgreSQL node, write SQL statements based on the syntax supported by PostgreSQL.

Step 3: Configure task scheduling

To run the task periodically, click Scheduling in the right-side panel of the node editor page. Configure the node's scheduling properties. For more information, see Overview of scheduling property configuration.

Note

You must set the Rerun attribute and Parent Nodes properties for the node before you can commit it.

Step 4: Debug the task

Follow these steps to debug the task and verify that it runs correctly.

  1. (Optional) Select a resource group for running the task and assign values to custom parameters.

    • Click the 高级运行 icon in the toolbar. In the Parameter dialog box, select the scheduling resource group to use for debugging.

    • If your code uses scheduling parameter variables, assign values to them for debugging. For more information about the parameter assignment logic, see Task debugging process.

  2. Save and run the SQL statements.

    Click the 保存 icon in the toolbar to save the SQL statements. Then, click the 运行 icon to run the SQL task.

  3. (Optional) Perform smoke testing.

    To verify the scheduled task in the development environment, you can perform smoke testing during or after the commit. For more information, see Perform smoke testing.

Step 5: Commit and deploy

After configuring the task, you must commit and deploy it. The task will then run periodically as scheduled.

  1. Click the Save icon in the toolbar to save the node.

  2. Click the 提交 icon in the toolbar to commit the task.

    In the Submission dialog box, enter a Change Description. You can also choose whether to perform a code review after the node is committed.

    Note
    • You must set the Rerun attribute and Parent Nodes properties for the node before you can commit it.

    • Code review improves code quality and prevents errors from unreviewed deployments. If you enable code review, a reviewer must approve the committed code before it can be deployed. For more information, see Code review.

If you use a workspace in standard mode, you must click Deploy in the upper-right corner of the editor after committing the task. This deploys the task to the production environment. For more information, see Deploy tasks.

Next steps

After the task is committed and deployed, it runs periodically as scheduled. You can click Operation Center in the upper-right corner of the node editor page to open Operation Center and view the task's scheduling status. For more information, see Manage periodic tasks.