All Products
Search
Document Center

MaxCompute:Analyze connections using SQL

Last Updated:Jul 10, 2026

Use the SQL analysis feature in the MaxCompute console to edit, run, and analyze SQL statements online.

Important

Alibaba Cloud has upgraded the SQL analysis feature in the MaxCompute console with all-region support. Explore the new capabilities and enable them in Connect using SQL analysis (new version).

The legacy SQL analysis entry point shuts down on March 31, 2026, UTC+8. Move local files from your legacy workspace to your personal directory in the new SQL analysis interface before that date.

Function overview

  • Edit and run SQL statements online, and visualize query results.

  • Built-in public dataset demos let you test MaxCompute features immediately.

Scenarios

  • Quick exploration: Use public datasets to explore core MaxCompute capabilities.

  • Ad hoc testing: Run temporary SQL commands, such as viewing table data.

SQL analysis interface

Editor area

Module

Description

Tab bar

File tabs let you open multiple files at once.

  • Double-click an empty area on the tab bar to create a new .sql file.

  • Right-click an empty area on the tab bar and select Create File.

Toolbar

  • Run: Execute the SQL script. Select a segment to run it alone; otherwise the entire file runs.

  • Stop: Appears after you click Run. Click Stop to stop the running script.

  • Save: Save files locally as .sql files. Cloud storage is not supported in the current public preview.

  • Format: Format the SQL code in the current file.

  • Run Result: Show the result pane if it is hidden after running a SQL script.

  • Cost Analysis: Run a COST SQL statement to estimate resource usage and get the scanned data volume and query complexity.

Editor

  • The first line of the script must contain executable code.

  • If a .sql file contains multiple SQL scripts, place any flags (SET statements) at the top. Flags apply to all SQL scripts in the file.

  • Supports full-screen mode for input, execution, and result viewing.

Run parameter configuration pane

Click Run Parameters in the top-right corner of the SQL editor to expand the configuration panel.

Module

Description

Project

  • Select the project to run the SQL code in. Required.

  • The selected project must grant your account create instance permission.

  • Required on first run. The system caches your last selection, which you can change anytime.

  • The selection applies to all open file tabs.

Computing Quota

  • Select a computing quota. Optional.

  • If you select a quota, it must grant your account usage permission.

  • If you do not select a quota, the system uses the project’s default computing quota.

  • The selection applies to all open file tabs.

Result pane

Module

Description

Issue

Automatically validates syntax and formatting for all open files before script execution.

MetaData

Select an object (table, resource, or function) from Table Data or DataSet Manage to view metadata: basic info, columns, DDL, and data preview.

Requires appropriate data permissions for the object.

Result

Displays script execution results:

  • Run list: Each SQL execution creates a timestamped record. Click a record to view its details.

  • Logs: Execution logs for each run.

  • SQL: The exact SQL code executed.

  • Result list: Displays query results if available.

  • Analysis: Perform simple chart-based analysis on results if available.

Cost Analysis

Shows results from the COST SQL statement executed during Cost Analysis, including execution logs and output.

Resource manager

Right-click an empty area in the resource manager to configure visible modules, such as hiding Timeline.

Module

Description

File list

  • On first access, displays No folder opened.

  • Click Open Folder to select a local folder. A permission confirmation dialog appears on first use.

Important

You must grant access permissions to all files each time a local folder is opened.

No folder contents are stored on the server.

CommonDataSet Demo

  • Built-in public dataset demo queries can be run or edited temporarily. Online demo files cannot be modified permanently—refreshing the page resets them. Save any modified files to your local machine.

  • Demo queries use public datasets with schemas. Scripts include set odps.namespace.schema=true; to enable schema syntax by default.

  • Each demo file contains multiple SQL scripts. The number before -query in the filename indicates the query count. TPC-DS demos contain 99 queries per file across different data volumes and consume significant compute resources—proceed with caution.

Timeline

Records operation logs for files opened in the editor. Logs are stored in browser cache and cleared when you clear the cache.

Search

Click the Search icon in the sidebar. The search box supports Match Case (Aa), Whole Words (ab), and Regular Expression (*). The replace box supports Preserve Case (AB).

Module

Description

Search

  • Search across all files in the resource manager—for example, find files containing "FROM table_test1".

  • Click a result to open the file and jump to the match.

Replacement

  • Replaces found keywords with new text.

  • Example: To replace FROM table_test1 with FROM table_test2 in all files, enter FROM table_test1 in the Search box, enter FROM table_test2 in the Replacement box, and click image.

Table data

Lists all objects across projects in the current tenant and region: schemas, tables, views, resources, and functions.

  • Visibility scope: Alibaba Cloud accounts can view all projects. RAM users must be added to a project to view its contents.

  • SYSTEM_CATALOG project: SYSTEM_CATALOG is a system-created project for tenant-level Information Schema. INFORMATION_SCHEMA views reside under the "INFORMATION_SCHEMA" schema in this project and are directly accessible.

  • View permissions: Viewing a project’s object list requires List permission.

    Tables with SELECT permission display a green icon image.

  • Schema hierarchy: Expand a project to see its schemas (if enabled) or object categories directly. Expand a category to view its objects.

  • Click an object to view its metadata details in the MetaData tab in the result pane.

Public datasets

In the SQL editor, click the database icon at the bottom of the left navigation pane. The Public Datasets entry appears at the top of the left panel. Expand BIGDATA_PUBLIC_DATASET to browse available tables.

Displays metadata for tables in system-provided public datasets.

Use SQL analysis

  • SQL jobs require a project. Create one after activating MaxCompute.

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

  2. Create a MaxCompute project

    SQL jobs require a project. Create one after activating MaxCompute.

  3. In the left-side navigation pane, choose Data Exploration > SQL Analysis.

  4. On the Data Exploration > SQL Analysis page, create an SQL file.

    1. When you open the SQL Analysis page for the first time, an SQL file named untitled_x is created and opened by default. You can edit this file directly.

    2. Double-click a blank area on the file tab bar in the editor to create an SQL file.

    3. Right-click the file tab bar in the editor and select New File.

  5. After you enter SQL in the SQL editor, click Run Configurations on the right and configure the Project and Computing Quota.

    • Project: Required. The project in which to execute the SQL statements. You must have the CREATE instance permission for this project.

    • Computing Quota: Optional. This parameter specifies the compute resource quota for the job. If you specify a quota, your account must have the USAGE permission for it. If you do not specify a quota, the SQL statements are executed using the default compute resource quota configured for the project.

  6. Click Run and wait for the query to complete. In the execution results, you can click the image icon to perform a simple visual analysis.

    The SQL analysis interface does not support result downloads. Use one of these methods:

  7. Click Save to save the current SQL file to your local computer.