All Products
Search
Document Center

MaxCompute:Project operations

Last Updated:Jan 23, 2026

After you create a MaxCompute project, you must enter the project to perform operations such as development, analysis, and O&M. This topic describes how to enter or view a project and set or view its project-level properties.

The following table lists the common commands for project operations.

Type

Feature

Role

Entry point

Enter a project

Enter a project to which you have access permissions.

A user who has access permissions on the project

The commands in this topic must be run on the MaxCompute client.

View project properties

View the property settings of a project.

Project owner

Set project properties

Set the properties of a project.

Project owner

View the account systems of a project

Display the account systems that are supported by the current project.

Project owner

Add the RAM user system

Add the RAM user system to the current project.

Project owner

Remove the RAM user system

Remove the RAM user system from the current project.

Project owner

MaxCompute does not provide commands to create or delete projects. For more information, see Create a MaxCompute project.

Get a project name

A MaxCompute project is different from a DataWorks workspace. You can obtain the project name as follows:

  1. Log on to the MaxCompute console and select a region in the top-left corner.

  2. In the navigation pane on the left, choose Manage Configurations > Projects.

  3. On the Projects page, obtain the name of the MaxCompute project.

Go to a project

Enter a project to which you have access permissions. After you enter the project, you can directly perform operations on objects in the project.

  • Command syntax

    -- Enter a project.
    USE <project_name>;
  • Parameters

    project_name: The name of the project that you want to access. An error is returned if the project does not exist or you do not have permissions to access the project.

  • Examples

    • Example 1: Enter a project and access an object in it.

      -- The current project is my_project. The project to be accessed is my_project_test. You have permissions to access my_project_test.
      odps@ my_project>USE my_project_test;
      -- After you enter the project, you can perform other operations. For example, you can query the test_src table in the my_project_test project.
      odps@ my_project_test>SELECT * FROM test_src;

      MaxCompute automatically searches for the table in the my_project_test project. If the table exists, the data in the table is returned. If the table does not exist, an error is returned.

    • Example 2: To access an object in another project, you must have the required permissions on the object and specify the project name.

      • The following is an example of what happens if the schema feature is disabled in MaxCompute:

        -- Access the test_src table in the my_project2 project from the my_project_test project.
        odps@ my_project_test>SELECT * FROM my_project2.test_src;
      • The following example applies when the schema feature is enabled for MaxCompute:

        -- Access the test_src table in the my_project2 project from the my_project_test project. The default schema of my_project2 is Default.
        odps@ my_project_test>SELECT * FROM my_project2.default.test_src;
        Note
        • For more information about granting permissions on objects in a destination project, see Project management.

        • For more information about the schema feature, see Schema operations.

View project properties

You can view the project-level property settings of the current project. MaxCompute also lets you view session-level properties. For more information, see show flags.

  • Command syntax

    SETPROJECT;
  • Property description

    The following are the common properties of a project.

    Property name (KEY)

    Description

    Value range (VALUE)

    odps.sql.allow.fullscan

    Specifies whether to allow full table scans in the project. Full table scans consume a large amount of computing resources. To improve processing efficiency, we recommend that you do not enable this feature.

    • true: Full table scans are allowed.

    • false: Full table scans are not allowed.

    odps.table.lifecycle

    Specifies whether a lifecycle must be configured for tables in the project.

    • optional: The Lifecycle clause is optional when you create a table. If you do not configure a lifecycle for a table, the table never expires.

    • mandatory: The Lifecycle clause is required. You must configure a lifecycle for the table.

    • inherit: If you do not configure a lifecycle for a table when you create the table, the lifecycle of the table is the value of odps.table.lifecycle.value.

    odps.table.lifecycle.value

    The lifecycle of a table. Unit: days.

    1 to 37231. The default value is 37231.

    odps.security.ip.whitelist

    The IP address whitelist that is allowed to access the project over the Internet. For more information, see Manage IP address whitelists.

    A list of IP addresses separated by commas (,).

    odps.security.vpc.whitelist

    The IP address whitelist that is allowed to access the project over a VPC. For more information, see Manage IP address whitelists.

    VPC instance ID1,VPC instance ID2[IP address list].

    READ_TABLE_MAX_ROW

    The number of data records that a SELECT statement can return.

    1 to 10000. The default value is 10000.

    odps.sql.type.system.odps2

    Enables or disables the new data types of MaxCompute V2.0. For more information about V2.0 data types, see Data type editions (V2.0).

    • true: enabled

    • false: disabled

    odps.sql.hive.compatible

    Enables or disables the Hive-compatible mode. After you enable the Hive-compatible mode, MaxCompute supports various Hive-specific syntax, such as inputRecordReader, outputRecordReader, and Serde. For more information about Hive-compatible data types, see Hive-compatible data type edition.

    • true: enabled

    • false: disabled

    odps.sql.decimal.odps2

    Enables or disables the DECIMAL(precision,scale) data type of MaxCompute V2.0. For more information, see Data type editions (V2.0).

    • true: enabled

    • false: disabled

    odps.sql.metering.value.max

    The maximum consumption of a single SQL statement. For more information, see Consumption control for monitoring and alerting.

    None.

    odps.sql.timezone

    The time zone of the MaxCompute project. For more information about time zones, see Time zone configurations.

    None.

    odps.sql.unstructured.oss.commit.mode

    Specifies whether to enable multipart upload to write data to OSS external tables. For more information, see Write data to OSS.

    • true: enabled

    • false: disabled

    odps.sql.groupby.orderby.position.alias

    Specifies whether to process integer constants in group by and order by clauses as the ordinal numbers of columns in the SELECT list.

    Note

    For an existing project, if you enable this parameter at the project level, the parsing and execution of existing tasks may be affected. Before you modify this parameter, make sure that existing tasks can run correctly based on the original logic after this parameter is set. Otherwise, set this parameter at the session level.

    • true: enabled

    • false: disabled

    odps.forbid.fetch.result.by.bearertoken

    Specifies whether to prevent the Result tab in Logview from displaying job running results. This parameter is used to protect data security.

    • true: Job running results are not displayed.

    • false: Displays the results of the job run.

    odps.cupidhistory.inprogress.remain.days

    The retention period of historical logs for running Spark on MaxCompute jobs. Unit: days.

    1 to 7. The default value is 7.

    odps.cupidhistory.remain.days

    The retention period of historical logs for Spark on MaxCompute jobs. Unit: days.

    1 to 3. The default value is 3.

    odps.ext.oss.orc.native

    Specifies whether to upgrade the implementation for parsing ORC data files when a job in the project reads an external table. The original implementation is based on the open source Java community. The new implementation is based on C++, supports later versions of ORC files, and improves the parsing performance of open source data by several times.

    • true: The new C++-based native implementation is used to parse ORC data files when an external table is read.

    • false: The original Java-based implementation from the open source community is used to parse ORC data files when an external table is read.

    odps.ext.parquet.native

    Specifies whether to upgrade the implementation for parsing PARQUET data files when a job in the project reads an external table. The original implementation is based on the open source Java community. The new implementation is based on C++ and improves the parsing performance of open source data by several times. After the upgrade, if there are many small PARQUET files and many data columns, the number of access requests to the data source may increase. When you create a table, you can use the with serdeproperties clause with the parquet.file.cache.size and parquet.io.buffer.size parameters to increase the amount of data cached for each access to the data source.

    • true: The new C++-based native implementation is used to parse PARQUET data files when an external table is read.

    • false: The original Java-based implementation from the open source community is used to parse PARQUET data files when an external table is read.

    odps.security.enabledownloadprivilege

    Specifies whether to enable the Download permission control solution for the project. After this feature is enabled, you can control the actions of roles or users who use Tunnel to download tables and instances. This improves data security and prevents data breaches. For more information, see Download permission control.

    • true: Enable Download permission control.

    • false: Disable Download permission control.

    odps.security.ip.whitelist.services

    The service whitelist. This parameter is used to avoid configuring an IP address whitelist when users use Alibaba Cloud services such as DataHub and SLS to access MaxCompute projects.

    Format: service1,service2.

    The service name must be registered in MaxCompute in advance.

    This parameter is often used for the LogShipper service. The value for Service is AliyunLogSLRService,AliyunLogDefaultService.

Set project properties

You can set the project-level properties of a project. The command to set project properties has a latency of 0 to 5 minutes. After the command is successfully run, wait 5 minutes and then verify the result. MaxCompute also lets you set session-level properties. For more information, see set.

  • Command syntax

    SETPROJECT <KEY>=<VALUE>;
  • Parameters

    • KEY: The property name.

    • VALUE: The property value. For more information about properties, see View project properties.

  • Example

    Allow full table scans in the project.

    SETPROJECT odps.sql.allow.fullscan=true;

View the account systems of a project

You can view the account systems that are supported by the current project. The account systems include ALIYUN and RAM. The command syntax is as follows:

LIST accountproviders;
Note

By default, a MaxCompute project can recognize only the Alibaba Cloud account system, not the RAM user system.

Add the RAM user system

You can add the RAM user system to the current project. The command syntax is as follows:

ADD accountprovider ram;

Remove the RAM user system

You can remove the RAM user system from the current project. The command syntax is as follows:

REMOVE accountprovider ram;