When iterating on SQL code, running the full node each time slows down debugging. The quick run feature lets you test a selected code snippet directly in the node editor without triggering a full scheduled run, so you can verify that a specific statement produces the expected result.
Prerequisites
Before you begin, ensure that you have:
-
An ODPS SQL or EMR Hive node created with code written
-
To create an ODPS SQL node, see Develop an ODPS SQL task.
-
To create an EMR Hive node, see Create an EMR Hive node.
-
Limitations
-
Only ODPS SQL and EMR Hive nodes support the quick run feature.
-
Quick run is only available when the node is not currently running. If the node is already executing, the quick run icon
does not appear next to the code line.
Billing
Quick run does not consume scheduling resources. You are charged only for the compute engine instances used. For billing details, see the billing documentation for the Alibaba Cloud service that your compute engine belongs to.
Run a code snippet
-
Go to the DataStudio page. Log on to the DataWorks console. In the top navigation bar, select a region. In the left-side navigation pane, choose Data Development and O&M > Data Development. Select a workspace and click Go to Data Development.
-
Open the node. In the left-side navigation pane, click Scheduled Workflow, Manually Triggered Workflows, or Ad Hoc Query. Find the ODPS SQL or EMR Hive node and double-click it to open the configuration tab.
-
For an overview of DataStudio features, see Data Studio feature guide.
-
To work with ad hoc queries, see Create an ad hoc query.
-
-
Select the code snippet to run. In the SQL code section, hover over any line of code. DataStudio automatically highlights the complete code snippet that the line belongs to.

-
Run the highlighted snippet.
Use one of the following methods:
Method Windows macOS Keyboard shortcut Ctrl+EnterCmd+EnterClick Click the quick run icon
to the left of the code lineClick the quick run icon
to the left of the code lineResource group: Quick run uses the resource group from the most recent execution of the node. The first time you run the node, select a resource group based on your business requirements. To create a new resource group, see Use exclusive resource groups for scheduling. To change the resource group, click the advanced run icon
in the top toolbar. You can also set the resource group for subsequent quick runs by using the run icon
or advanced run icon
in the top toolbar.Variables: If the code snippet contains variables, specify their values the first time you run it. DataStudio saves the values for subsequent runs. To change variable values, click the advanced run icon
. For supported variable formats, see Supported formats for scheduling parameters. -
View the execution result. After the run completes, you can view the execution result. If the result is unexpected, modify the code snippet and run it again.