Hologres SQL node

更新时间:
复制 MD 格式

Hologres integrates seamlessly with MaxCompute, letting you use standard PostgreSQL statements to query and analyze massive data in MaxCompute without data movement and retrieve results quickly.

Prerequisites

You have bound a Hologres compute resource.

Procedure

  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. Create a Workflow.

    If you already have a Workflow, you can skip this step.

    1. Hover over the 新建 icon and select Workflow.

    2. In the Create Workflow dialog box, enter a Workflow Name.

    3. Click Create.

  3. Create a Hologres SQL node.

    1. Hover over the 新建 icon and click Create Node > Hologres > Hologres SQL.

      Alternatively, find the target workflow, right-click Hologres, and select Create Node > Hologres SQL.

    2. In the Create Node dialog box, enter a Node Name.

      Note

      The node name must be 128 characters or fewer and can contain letters, Chinese characters, digits, underscores (_), and periods (.).

    3. Click OK.

  4. In the node editor, write and run the code.

    After you create the node, write valid Hologres SQL code. For more information about the SQL syntax, see SELECT.

    Note

    A SELECT query without a limit clause returns a maximum of 200 results by default. To display more results, add a limit clause to the SELECT statement. A maximum of 10,000 results can be returned.

    For example, the select col_1,col_2 from your_table_name where pt>0 limit 500; statement returns 500 results.

  5. On the right side of the node editor, click Scheduling Properties to configure the node's scheduling properties. For more information, see Configure basic properties.
  6. Save and commit the node.
    Important

    You must configure the rerun property and specify the parent nodes for the node before committing it.

    1. Click the 保存 icon in the toolbar to save the node.
    2. Click the 提交 icon in the toolbar.
    3. In the Submit New Version dialog box, enter a Change description.
    4. Click OK.
    If you use a workspace in standard mode, click Deploy in the upper-right corner after you commit the node. For more information, see Deploying tasks.
  7. For task O&M, see Basic O&M for scheduled tasks.