DataWorks allows you to view, modify, and delete tables in MaxCompute, AnalyticDB for PostgreSQL, and E-MapReduce. You can view and manage these tables by type on the Table Management tab of the DataStudio page.

Prerequisites

Manage tables

  1. Go to the DataStudio page.
    1. Log on to the DataWorks console.
    2. In the left-side navigation pane, click Workspaces.
    3. In the top navigation bar, select the region where the target workspace resides. Find the target workspace and click Data Analytics in the Actions column.
  2. On the left-side navigation submenu, click the Table Management icon.
    You can click the Show icon icon in the lower-left corner to show or hide the left-side navigation submenu.
  3. Select an engine type from the drop-down list at the top of the Table Management tab. The corresponding tables appear.
    Table Management
    Tables in MaxCompute are used in this example to describe how to view, modify, and delete tables in DataWorks. For more information about how to create a table, see Table.
    Operation Description
    View tables in different environments In the left-side navigation pane, click the Filter icon icon next to the search box and select an environment.
    Note
    • For a workspace in standard mode, the Table Management tab displays tables in both the development and production environments.

      For a workspace in basic mode, the Table Management tab displays only the tables in the production environment.

    • The current environment is highlighted in blue.

    Double-click a table. The configuration tab of the table appears and displays details of the table.

    Rename a table Right-click a table and select Rename table. In the Rename table dialog box, enter a name and click OK.
    Import data to a table Right-click a table and select Import data. For more information, see Create tables and import data.
    Delete a table You can delete a table in either the development or production environment.
    • Delete a table in the development environment:
      1. Before you delete a table, make sure that you have the permission to delete the table. Right-click a table and select Delete table.
      2. In the Delete table dialog box, select I have known the risks and confirmed the deletion.
      3. Click OK.

      If the name of a table starts with tmp_pyodps, the table is of the PyODPS type. For more information, see PyODPS node.

    • Delete a table in the production environment:
      1. Create an ODPS SQL node. For more information, see ODPS SQL node.
      2. On the configuration tab of the ODPS SQL node, enter and execute an SQL statement to delete the table.
      3. Commit and deploy the node to the production environment.

Divide a data warehouse into layers

In the Physical model design section of the configuration tab of a table, you can define table layers for a data warehouse. This allows you to have better planning and control over your data.

Typically, a data warehouse consists of the following layers:
  • The ODS layer stores raw data in the data warehouse. The data structure is basically consistent with that in the source system. The ODS layer serves as the data staging area of the data warehouse. It imports basic data to MaxCompute and records historical changes of basic data.
  • The CDM layer, which is also called the general data model layer, consists of the dimension data (DIM), data warehouse detail (DWD), and data warehouse service (DWS) layers. The CDM layer processes and integrates the data of the ODS layer to define conformed dimensions, create reusable detailed fact tables for analysis and statistics, and aggregate common metrics.
    • The DIM layer defines conformed dimensions for an enterprise based on the concepts of dimensional modeling. It reduces the risk of inconsistent statistical criteria and algorithms.

      Tables at the DIM layer are also called logical dimension tables. Generally, each dimension corresponds to a logical dimension table.

    • The DWS layer is driven by analyzed subjects during data modeling. Based on the metric requirements of upper-layer applications and products, the DWS layer creates fact tables to aggregate common metrics and builds a physical data model by using wide tables. The DWS layer creates statistical metrics in compliance with uniform naming conventions and statistical criteria, provides common metrics for the upper layer, and generates aggregate wide tables and detailed fact tables.

      Tables at the DWS layer are also called logical aggregate tables, which are used to store derived metrics.

    • The DWD layer is driven by business processes during data modeling. It creates detailed fact tables at the finest granularity based on each specific business process. In combination with the data usage habits of an enterprise, you can duplicate some key attribute fields of dimensions in detailed fact tables to create wide tables.

      Tables at the DWD layer are also called logical fact tables.

  • The ADS layer stores personalized statistical metrics of data products. It processes the data of the CDM and ODS layers.