Compute
Elastic Cloud Server
Huawei Cloud Flexus
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Cloud Phone Host
Huawei Cloud EulerOS
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
VPC Endpoint
Cloud Connect
Enterprise Router
Enterprise Switch
Global Accelerator
Management & Governance
Cloud Eye
Identity and Access Management
Cloud Trace Service
Resource Formation Service
Tag Management Service
Log Tank Service
Config
OneAccess
Resource Access Manager
Simple Message Notification
Application Performance Management
Application Operations Management
Organizations
Optimization Advisor
IAM Identity Center
Cloud Operations Center
Resource Governance Center
Migration
Server Migration Service
Object Storage Migration Service
Cloud Data Migration
Migration Center
Cloud Ecosystem
KooGallery
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP Filing
Support Plans
My Credentials
Customer Operation Capabilities
Partner Support Plans
Professional Services
Analytics
MapReduce Service
Data Lake Insight
CloudTable Service
Cloud Search Service
Data Lake Visualization
Data Ingestion Service
GaussDB(DWS)
DataArts Studio
Data Lake Factory
DataArts Lake Formation
IoT
IoT Device Access
Others
Product Pricing Details
System Permissions
Console Quick Start
Common FAQs
Instructions for Associating with a HUAWEI CLOUD Partner
Message Center
Security & Compliance
Security Technologies and Applications
Web Application Firewall
Host Security Service
Cloud Firewall
SecMaster
Anti-DDoS Service
Data Encryption Workshop
Database Security Service
Cloud Bastion Host
Data Security Center
Cloud Certificate Manager
Edge Security
Managed Threat Detection
Blockchain
Blockchain Service
Web3 Node Engine Service
Media Services
Media Processing Center
Video On Demand
Live
SparkRTC
MetaStudio
Storage
Object Storage Service
Elastic Volume Service
Cloud Backup and Recovery
Storage Disaster Recovery Service
Scalable File Service Turbo
Scalable File Service
Volume Backup Service
Cloud Server Backup Service
Data Express Service
Dedicated Distributed Storage Service
Containers
Cloud Container Engine
SoftWare Repository for Container
Application Service Mesh
Ubiquitous Cloud Native Service
Cloud Container Instance
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GeminiDB
GaussDB
Distributed Database Middleware
Database and Application Migration UGO
TaurusDB
Middleware
Distributed Cache Service
API Gateway
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
Multi-Site High Availability Service
EventGrid
Dedicated Cloud
Dedicated Computing Cluster
Business Applications
Workspace
ROMA Connect
Message & SMS
Domain Name Service
Edge Data Center Management
Meeting
AI
Face Recognition Service
Graph Engine Service
Content Moderation
Image Recognition
Optical Character Recognition
ModelArts
ImageSearch
Conversational Bot Service
Speech Interaction Service
Huawei HiLens
Video Intelligent Analysis Service
Developer Tools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Content Delivery & Edge Computing
Content Delivery Network
Intelligent EdgeFabric
CloudPond
Intelligent EdgeCloud
Solutions
SAP Cloud
High Performance Computing
Developer Services
ServiceStage
CodeArts
CodeArts PerfTest
CodeArts Req
CodeArts Pipeline
CodeArts Build
CodeArts Deploy
CodeArts Artifact
CodeArts TestPlan
CodeArts Check
CodeArts Repo
Cloud Application Engine
MacroVerse aPaaS
KooMessage
KooPhone
KooDrive

Opening Multiple SQL Terminal Tabs

Updated on 2022-08-16 GMT+08:00

You can open multiple SQL Terminal tabs in Data Studio to execute multiple SQL statements for query in the current SQL Terminal tab. Perform the following steps to open a new SQL Terminal tab:

You can also open multiple SQL Terminal tabs on different connection templates.

  1. In the Object Browser pane, right-click the desired database and choose Open Terminal from the shortcut menu. Alternatively, click in the toolbar or press Ctrl+T to open a new SQL terminal.

    The SQL Terminal tab is displayed.

NOTE:
  • In Data Studio, a maximum of 100 SQL Terminal tabs can be opened for each connected database. Based on the number of query times, each SQL Terminal tab contains multiple Result tabs and one Message tab. If the database connection is lost, the corresponding SQL Terminal tab is still available.
  • The restoration operation applies to all minimized SQL Terminal tabs. You cannot restore a single tab.
  • After all terminals are shut down, Data Studio resets the counter of the SQL terminal.
  • After all Result Set tabs are closed, Data Studio resets the counter of the result set.
  • Data Studio allows you to reset counters in the following pages: Display DDL User/Role, Batch Delete, Result Set, and Execution Plan.

Data Studio displays an error message indicating that no result is found in the status bar. The Result tab displays the successful execution results.

Perform the following steps to open a new SQL Terminal tab in another connection:

  1. Select the required connection from the connection list in the toolbar.
  2. In the Object Browser pane, right-click the desired connected database and choose Open Terminal, or click in the toolbar. The SQL Terminal tab is displayed.

    The name format of the new SQL Terminal tab is as follows:

    Database name@Connection information(Tab number), for example, postgres@IDG_1(2). The number of each SQL Terminal tab in the same connection information is unique.

Right-Click Menus in the Result Tab

You can copy or export cell data to an Excel file and generate a SQL query file.

After the SQL query result is displayed in the Result tab, right-click the result. The following menu is displayed:

Perform the following steps to add a row number and column header to the result set:

  1. On the menu bar of Data Studio, click Settings.
  2. Choose Preferences.
  3. Expand the Result Management tab and choose Query Results.
  4. In the Result Advanced Copy area, select Include column header and Include row number.

The following table describes the right-click options.

Table 1 Right-click options

Option

Sub-Item

Description

Copy Data

Copy

Copies data in the selected cell.

Advanced Copy

Copies data in the selected cell, row number, and column header based on the preference settings.

Copy to Excel

Copy as xls

Exports data of selected cells to an xls file, which contains a maximum of 64,000 rows and 256 columns.

Copy as xlsx

Exports data of selected cells to an xlsx file, which contains a maximum of 1 million rows.

Export

Current Page

Exports the table data on the current page.

All Pages

Exports all tables.

Generate SQL

Selected Line

Selects data from the target table of the statement for inserting data to generate a SQL file.

Current Page

Selects data of the current page from the target table of the statement for inserting data to generate a SQL file.

All Pages

Selects all table data from the target table of the statement for inserting data to generate a SQL file.

Set Null

-

Sets the cell data to null.

Search

-

Searches for data in the selected cell and displays all data that meets the search criteria.

NOTE:

The preceding SQL files do not take effect for the result sets generated by queries that use JOIN, expressions, views, SET operators, aggregate functions, GROUP BY clauses, or column aliases.

Displaying Execution Progress Bar

When a query is executed in the SQL Terminal pane, a progress bar is displayed to dynamically display the execution duration. After the query is complete, the time bar disappears. The total execution duration is displayed next to the time bar.

If you want to cancel the query, click Cancel next to the time bar.

The procedure is shown in the following figure.

NOTE:
  • The Cancel button is deleted from the toolbar.
  • The progress bar is also displayed when you compile or debug an object in the PL/SQL editor.
  • The time format displayed in the progress bar is w hour x minute y second z millisecond.
  • When queries are performed in batches in SQL Terminal, the progress bar displays the total time consumed by the queries.

We use cookies to improve our site and your experience. By continuing to browse our site you accept our cookie policy. Find out more

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback